Skip to content

Commit 96cfa0c

Browse files
committed
---
yaml --- r: 90047 b: refs/heads/master c: 1f7bfac h: refs/heads/master i: 90045: da1238b 90043: 0ab5eef 90039: b27a2a2 90031: 3fc4e4c 90015: 7c1b61a 89983: fbca3a8 v: v3
1 parent 50c87d0 commit 96cfa0c

File tree

7 files changed

+14
-60
lines changed

7 files changed

+14
-60
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
refs/heads/master: 6ff697d3933754bf9ec5ee5875f487f02a7d087d
2+
refs/heads/master: 1f7bfac9d28340b3eda0291dd01b7914c77a88ae
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: a6d3e57dca68fde4effdda3e4ae2887aa535fcd6
55
refs/heads/try: b160761e35efcd1207112b3b782c06633cf441a8

trunk/src/librustc/middle/lint.rs

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -803,6 +803,11 @@ fn check_heap_item(cx: &Context, it: &ast::item) {
803803
// also make error on obsolete attributes for less confusion.
804804
fn check_item_attribute_usage(cx: &Context, it: &ast::item) {
805805
let crate_attrs = ["crate_type", "link", "feature", "no_uv", "no_main", "no_std"];
806+
let obsolete_attrs = [
807+
("abi", "extern \"abi\" fn"),
808+
("auto_encode", "#[deriving(Encodable)]"),
809+
("auto_decode", "#[deriving(Decodable)]"),
810+
];
806811

807812
for attr in it.attrs.iter() {
808813
let name = attr.node.value.name();
@@ -816,6 +821,13 @@ fn check_item_attribute_usage(cx: &Context, it: &ast::item) {
816821
cx.span_lint(attribute_usage, attr.span, msg);
817822
}
818823
}
824+
825+
for &(obs_attr, obs_alter) in obsolete_attrs.iter() {
826+
if name.equiv(&obs_attr) {
827+
cx.span_lint(attribute_usage, attr.span,
828+
format!("obsolete attribute: use `{:s}` instead", obs_alter));
829+
}
830+
}
819831
}
820832
}
821833

trunk/src/libstd/io/native/process.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -365,7 +365,6 @@ fn spawn_process_os(prog: &str, args: &[~str],
365365
use libc::funcs::bsd44::getdtablesize;
366366

367367
mod rustrt {
368-
#[abi = "cdecl"]
369368
extern {
370369
pub fn rust_unset_sigprocmask();
371370
}

trunk/src/libsyntax/ext/auto_encode.rs

Lines changed: 0 additions & 35 deletions
This file was deleted.

trunk/src/libsyntax/ext/base.rs

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ pub enum MacResult {
143143
}
144144

145145
pub enum SyntaxExtension {
146-
// #[auto_encode] and such
146+
// #[deriving] and such
147147
ItemDecorator(ItemDecorator),
148148

149149
// Token-tree expanders
@@ -229,12 +229,6 @@ pub fn syntax_expander_table() -> SyntaxEnv {
229229
syntax_expanders.insert(intern(&"format_args"),
230230
builtin_normal_tt_no_ctxt(
231231
ext::format::expand_args));
232-
syntax_expanders.insert(
233-
intern(&"auto_encode"),
234-
@SE(ItemDecorator(ext::auto_encode::expand_auto_encode)));
235-
syntax_expanders.insert(
236-
intern(&"auto_decode"),
237-
@SE(ItemDecorator(ext::auto_encode::expand_auto_decode)));
238232
syntax_expanders.insert(intern(&"env"),
239233
builtin_normal_tt_no_ctxt(
240234
ext::env::expand_env));

trunk/src/libsyntax/lib.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,6 @@ pub mod ext {
8383
pub mod concat;
8484
pub mod concat_idents;
8585
pub mod log_syntax;
86-
pub mod auto_encode;
8786
pub mod source_util;
8887

8988
pub mod trace_macros;

trunk/src/test/compile-fail/deprecated-auto-code.rs

Lines changed: 0 additions & 15 deletions
This file was deleted.

0 commit comments

Comments
 (0)