From 359ac360a453b31494d18bf838f6620032a663e5 Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Fri, 14 Feb 2014 10:03:53 -0800 Subject: [PATCH 1/2] Register new snapshots This enables the parser error for `extern mod` => `extern crate` transitions. --- src/libstd/hashmap.rs | 6 ++---- src/libstd/rt/env.rs | 11 ----------- src/libstd/rt/local_heap.rs | 3 --- src/libstd/vec.rs | 6 ++---- src/libsyntax/parse/parser.rs | 13 ++++++------- src/snapshots.txt | 8 ++++++++ src/test/auxiliary/crateresolve_calories-1.rs | 5 ----- src/test/auxiliary/crateresolve_calories-2.rs | 5 ----- 8 files changed, 18 insertions(+), 39 deletions(-) diff --git a/src/libstd/hashmap.rs b/src/libstd/hashmap.rs index f8e02c82fcd99..1ac599d0654fb 100644 --- a/src/libstd/hashmap.rs +++ b/src/libstd/hashmap.rs @@ -56,7 +56,7 @@ use container::{Container, Mutable, Map, MutableMap, Set, MutableSet}; use clone::Clone; use cmp::{Eq, Equiv, max}; use default::Default; -#[cfg(not(stage0))] use fmt; +use fmt; use hash::Hash; use iter; use iter::{Iterator, FromIterator, Extendable}; @@ -66,7 +66,7 @@ use num; use option::{None, Option, Some}; use rand::Rng; use rand; -#[cfg(not(stage0))] use result::{Ok, Err}; +use result::{Ok, Err}; use vec::{ImmutableVector, MutableVector, OwnedVector, Items, MutItems}; use vec_ng; use vec_ng::Vec; @@ -597,7 +597,6 @@ impl Clone for HashMap { } } -#[cfg(not(stage0))] impl fmt::Show for HashMap { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { if_ok!(write!(f.buf, r"\{")) @@ -876,7 +875,6 @@ impl Clone for HashSet { } } -#[cfg(not(stage0))] impl fmt::Show for HashSet { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { if_ok!(write!(f.buf, r"\{")) diff --git a/src/libstd/rt/env.rs b/src/libstd/rt/env.rs index 571ed77592fcc..94f56d42613fd 100644 --- a/src/libstd/rt/env.rs +++ b/src/libstd/rt/env.rs @@ -10,8 +10,6 @@ //! Runtime environment settings -// NOTE: remove `POISON_ON_FREE` after a snapshot - use from_str::from_str; use option::{Some, None}; use os; @@ -23,7 +21,6 @@ static mut MIN_STACK: uint = 2 * 1024 * 1024; /// This default corresponds to 20M of cache per scheduler (at the default size). static mut MAX_CACHED_STACKS: uint = 10; static mut DEBUG_BORROW: bool = false; -static mut POISON_ON_FREE: bool = false; pub fn init() { unsafe { @@ -43,10 +40,6 @@ pub fn init() { Some(_) => DEBUG_BORROW = true, None => () } - match os::getenv("RUST_POISON_ON_FREE") { - Some(_) => POISON_ON_FREE = true, - None => () - } } } @@ -61,7 +54,3 @@ pub fn max_cached_stacks() -> uint { pub fn debug_borrow() -> bool { unsafe { DEBUG_BORROW } } - -pub fn poison_on_free() -> bool { - unsafe { POISON_ON_FREE } -} diff --git a/src/libstd/rt/local_heap.rs b/src/libstd/rt/local_heap.rs index 7acce2ecb5ba9..f3474b9401e1a 100644 --- a/src/libstd/rt/local_heap.rs +++ b/src/libstd/rt/local_heap.rs @@ -17,7 +17,6 @@ use ops::Drop; use option::{Option, None, Some}; use ptr; use ptr::RawPtr; -use rt::env; use rt::global_heap; use rt::local::Local; use rt::task::Task; @@ -41,7 +40,6 @@ pub struct MemoryRegion { pub struct LocalHeap { priv memory_region: MemoryRegion, - priv poison_on_free: bool, priv live_allocs: *mut raw::Box<()>, } @@ -54,7 +52,6 @@ impl LocalHeap { }; LocalHeap { memory_region: region, - poison_on_free: env::poison_on_free(), live_allocs: ptr::mut_null(), } } diff --git a/src/libstd/vec.rs b/src/libstd/vec.rs index cfe2ad5a08af4..a1c5e83db44e7 100644 --- a/src/libstd/vec.rs +++ b/src/libstd/vec.rs @@ -108,7 +108,7 @@ use container::{Container, Mutable}; use cmp::{Eq, TotalOrd, Ordering, Less, Equal, Greater}; use cmp; use default::Default; -#[cfg(not(stage0))] use fmt; +use fmt; use iter::*; use num::{Integer, CheckedAdd, Saturating, checked_next_power_of_two}; use option::{None, Option, Some}; @@ -116,7 +116,7 @@ use ptr::to_unsafe_ptr; use ptr; use ptr::RawPtr; use rt::global_heap::{malloc_raw, realloc_raw, exchange_free}; -#[cfg(not(stage0))] use result::{Ok, Err}; +use result::{Ok, Err}; use mem; use mem::size_of; use kinds::marker; @@ -2643,7 +2643,6 @@ impl DeepClone for ~[A] { } } -#[cfg(not(stage0))] impl<'a, T: fmt::Show> fmt::Show for &'a [T] { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { if_ok!(write!(f.buf, "[")); @@ -2660,7 +2659,6 @@ impl<'a, T: fmt::Show> fmt::Show for &'a [T] { } } -#[cfg(not(stage0))] impl fmt::Show for ~[T] { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { self.as_slice().fmt(f) diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs index a02971ae8eaf2..f602925140b65 100644 --- a/src/libsyntax/parse/parser.rs +++ b/src/libsyntax/parse/parser.rs @@ -4566,13 +4566,12 @@ impl Parser { let next_is_mod = self.eat_keyword(keywords::Mod); if next_is_mod || self.eat_keyword(keywords::Crate) { - // NOTE(flaper87): Uncomment this when this changes gets into stage0 - // - // if next_is_mod { - // self.span_err(self.span, - // format!("`extern mod` is obsolete, use `extern crate` instead \ - // to refer to external crates.")) - // } + if next_is_mod { + self.span_err(self.span, + format!("`extern mod` is obsolete, use \ + `extern crate` instead \ + to refer to external crates.")) + } return self.parse_item_extern_crate(lo, visibility, attrs); } diff --git a/src/snapshots.txt b/src/snapshots.txt index 2db884fdb6436..88966a618358c 100644 --- a/src/snapshots.txt +++ b/src/snapshots.txt @@ -1,3 +1,11 @@ +S 2014-02-14 18477ac + freebsd-x86_64 102df7dfab2a1c59d9e2f16a3f02f368310dd022 + linux-i386 fcf5891e9b3c7c9ef5ee5ea37e62089346099425 + linux-x86_64 d7c2df185fd2e25b4b8f5b2caad277b5ba664b81 + macos-i386 + macos-x86_64 + winnt-i386 f78a892f47627f34233e44c2ff4a00b68063a2ce + S 2014-02-12 c62f6ce freebsd-x86_64 737a423c5f803119ff5a692eac432fa9d0c595a8 linux-i386 a7e90e27e8b6a3fa79ddc15f0ed217ccbade875d diff --git a/src/test/auxiliary/crateresolve_calories-1.rs b/src/test/auxiliary/crateresolve_calories-1.rs index 39328f28beace..54219de810707 100644 --- a/src/test/auxiliary/crateresolve_calories-1.rs +++ b/src/test/auxiliary/crateresolve_calories-1.rs @@ -9,11 +9,6 @@ // except according to those terms. #[crate_id="crateresolve_calories#0.1"]; -// NOTE: remove after the next snapshot -#[link(name = "crateresolve_calories", - vers = "0.1", - calories = "100")]; - #[crate_type = "lib"]; pub fn f() -> int { 100 } diff --git a/src/test/auxiliary/crateresolve_calories-2.rs b/src/test/auxiliary/crateresolve_calories-2.rs index edf90589db799..3b949b48613e4 100644 --- a/src/test/auxiliary/crateresolve_calories-2.rs +++ b/src/test/auxiliary/crateresolve_calories-2.rs @@ -9,11 +9,6 @@ // except according to those terms. #[crate_id="crateresolve_calories#0.1"]; -// NOTE: remove after the next snapshot -#[link(name = "crateresolve_calories", - vers = "0.1", - calories = "200")]; - #[crate_type = "lib"]; pub fn f() -> int { 200 } From a41b0c25295e06b8eebc4bdcb3021354f766cba0 Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Fri, 14 Feb 2014 10:10:06 -0800 Subject: [PATCH 2/2] extern mod => extern crate This was previously implemented, and it just needed a snapshot to go through --- src/compiletest/compiletest.rs | 4 +- src/doc/favicon.inc | 2 +- src/doc/guide-runtime.md | 2 +- src/doc/guide-tasks.md | 16 +-- src/doc/guide-testing.md | 4 +- src/doc/po/ja/complement-cheatsheet.md.po | 4 +- src/doc/po/ja/guide-conditions.md.po | 4 +- src/doc/po/ja/guide-container.md.po | 4 +- src/doc/po/ja/guide-ffi.md.po | 4 +- src/doc/po/ja/guide-pointers.md.po | 32 ++--- src/doc/po/ja/guide-runtime.md.po | 10 +- src/doc/po/ja/guide-testing.md.po | 2 +- src/doc/po/ja/rust.md.po | 50 +++---- src/doc/po/ja/tutorial.md.po | 126 +++++++++--------- src/doc/rust.md | 20 +-- src/doc/rustdoc.md | 4 +- src/doc/tutorial.md | 38 +++--- src/doc/version_info.html.template | 2 +- src/driver/driver.rs | 4 +- src/etc/combine-tests.py | 4 +- src/etc/emacs/rust-mode.el | 5 +- src/etc/extract-tests.py | 10 +- src/etc/generate-deriving-span-tests.py | 2 +- src/libarena/lib.rs | 7 +- src/libcollections/lib.rs | 7 +- src/libextra/json.rs | 12 +- src/libextra/lib.rs | 6 +- src/libextra/test.rs | 4 +- src/libfourcc/lib.rs | 4 +- src/libgetopts/lib.rs | 2 +- src/libgreen/lib.rs | 2 +- src/libnative/lib.rs | 4 +- src/libnum/lib.rs | 2 +- src/librustc/front/test.rs | 2 +- src/librustc/lib.rs | 16 +-- src/librustc/metadata/creader.rs | 2 +- src/librustc/metadata/cstore.rs | 2 +- src/librustc/middle/resolve.rs | 4 +- src/librustdoc/html/render.rs | 2 +- src/librustdoc/lib.rs | 14 +- src/librustdoc/test.rs | 4 +- src/librustuv/lib.rs | 2 +- src/libserialize/base64.rs | 4 +- src/libserialize/hex.rs | 4 +- src/libserialize/lib.rs | 2 +- src/libstd/lib.rs | 12 +- src/libsync/sync/mutex.rs | 2 +- src/libsyntax/ast.rs | 2 +- src/libsyntax/lib.rs | 8 +- src/libsyntax/parse/parser.rs | 20 +-- src/libsyntax/print/pprust.rs | 2 +- src/libuuid/lib.rs | 4 +- src/snapshots.txt | 4 +- src/test/auxiliary/crateresolve4b-1.rs | 2 +- src/test/auxiliary/crateresolve4b-2.rs | 2 +- src/test/auxiliary/crateresolve7x.rs | 4 +- src/test/auxiliary/issue-2414-b.rs | 2 +- src/test/auxiliary/issue-2526.rs | 2 +- src/test/auxiliary/issue-2631-a.rs | 2 +- src/test/auxiliary/issue-9906.rs | 2 +- src/test/auxiliary/issue2378b.rs | 2 +- src/test/auxiliary/issue_2242_c.rs | 2 +- src/test/auxiliary/issue_2316_b.rs | 2 +- .../macro_crate_outlive_expansion_phase.rs | 2 +- src/test/auxiliary/macro_crate_test.rs | 2 +- src/test/auxiliary/pub_use_xcrate2.rs | 2 +- .../trait_default_method_xc_aux_2.rs | 2 +- src/test/bench/core-map.rs | 4 +- src/test/bench/core-set.rs | 4 +- src/test/bench/core-std.rs | 2 +- src/test/bench/msgsend-pipes-shared.rs | 2 +- src/test/bench/msgsend-pipes.rs | 2 +- src/test/bench/msgsend-ring-mutex-arcs.rs | 4 +- src/test/bench/msgsend-ring-rw-arcs.rs | 4 +- src/test/bench/rt-messaging-ping-pong.rs | 2 +- src/test/bench/rt-parfib.rs | 2 +- src/test/bench/rt-spawn-rate.rs | 2 +- src/test/bench/shootout-ackermann.rs | 2 +- src/test/bench/shootout-binarytrees.rs | 4 +- src/test/bench/shootout-chameneos-redux.rs | 2 +- src/test/bench/shootout-fibo.rs | 2 +- src/test/bench/shootout-k-nucleotide-pipes.rs | 2 +- src/test/bench/shootout-k-nucleotide.rs | 2 +- src/test/bench/shootout-pfib.rs | 4 +- src/test/bench/shootout-pidigits.rs | 2 +- src/test/bench/shootout-spectralnorm.rs | 2 +- src/test/bench/std-smallintmap.rs | 4 +- src/test/bench/sudoku.rs | 2 +- src/test/bench/task-perf-alloc-unwind.rs | 4 +- src/test/compile-fail/ambig_impl_2_exe.rs | 2 +- .../compile-fail/arc-cant-nest-rw-arc-3177.rs | 2 +- .../arc-rw-cond-shouldnt-escape.rs | 2 +- .../arc-rw-read-mode-shouldnt-escape.rs | 2 +- .../arc-rw-state-shouldnt-escape.rs | 2 +- .../arc-rw-write-mode-cond-shouldnt-escape.rs | 2 +- .../arc-rw-write-mode-shouldnt-escape.rs | 2 +- .../builtin-superkinds-in-metadata.rs | 2 +- .../compile-fail/coherence_inherent_cc.rs | 2 +- .../conflicting-implementations-aux.rs | 2 +- src/test/compile-fail/crateresolve1.rs | 2 +- src/test/compile-fail/crateresolve2.rs | 4 +- src/test/compile-fail/crateresolve5.rs | 4 +- ...deriving-span-Clone-enum-struct-variant.rs | 2 +- .../compile-fail/deriving-span-Clone-enum.rs | 2 +- .../deriving-span-Clone-struct.rs | 2 +- .../deriving-span-Clone-tuple-struct.rs | 2 +- ...ving-span-DeepClone-enum-struct-variant.rs | 2 +- .../deriving-span-DeepClone-enum.rs | 2 +- .../deriving-span-DeepClone-struct.rs | 2 +- .../deriving-span-DeepClone-tuple-struct.rs | 2 +- .../deriving-span-Default-struct.rs | 2 +- .../deriving-span-Default-tuple-struct.rs | 2 +- .../deriving-span-Eq-enum-struct-variant.rs | 2 +- .../compile-fail/deriving-span-Eq-enum.rs | 2 +- .../compile-fail/deriving-span-Eq-struct.rs | 2 +- .../deriving-span-Eq-tuple-struct.rs | 2 +- .../deriving-span-Ord-enum-struct-variant.rs | 2 +- .../compile-fail/deriving-span-Ord-enum.rs | 2 +- .../compile-fail/deriving-span-Ord-struct.rs | 2 +- .../deriving-span-Ord-tuple-struct.rs | 2 +- .../deriving-span-Rand-enum-struct-variant.rs | 2 +- .../compile-fail/deriving-span-Rand-enum.rs | 2 +- .../compile-fail/deriving-span-Rand-struct.rs | 2 +- .../deriving-span-Rand-tuple-struct.rs | 2 +- .../deriving-span-Show-enum-struct-variant.rs | 2 +- .../compile-fail/deriving-span-Show-enum.rs | 2 +- .../compile-fail/deriving-span-Show-struct.rs | 2 +- .../deriving-span-Show-tuple-struct.rs | 2 +- ...riving-span-TotalEq-enum-struct-variant.rs | 2 +- .../deriving-span-TotalEq-enum.rs | 2 +- .../deriving-span-TotalEq-struct.rs | 2 +- .../deriving-span-TotalEq-tuple-struct.rs | 2 +- ...iving-span-TotalOrd-enum-struct-variant.rs | 2 +- .../deriving-span-TotalOrd-enum.rs | 2 +- .../deriving-span-TotalOrd-struct.rs | 2 +- .../deriving-span-TotalOrd-tuple-struct.rs | 2 +- .../compile-fail/deriving-span-Zero-struct.rs | 2 +- .../deriving-span-Zero-tuple-struct.rs | 2 +- .../functional-struct-update-noncopyable.rs | 2 +- src/test/compile-fail/future_not_copyable.rs | 2 +- .../compile-fail/gated-non-ascii-idents.rs | 2 +- src/test/compile-fail/gated-phase.rs | 2 +- src/test/compile-fail/gated-simd.rs | 2 +- src/test/compile-fail/issue-11593.rs | 2 +- src/test/compile-fail/issue-3021-b.rs | 2 +- src/test/compile-fail/issue-3021-c.rs | 2 +- src/test/compile-fail/issue-3021-d.rs | 2 +- src/test/compile-fail/issue-3021.rs | 2 +- src/test/compile-fail/issue-3907.rs | 2 +- src/test/compile-fail/issue-5844.rs | 2 +- src/test/compile-fail/issue-9957.rs | 6 +- src/test/compile-fail/lint-stability.rs | 2 +- src/test/compile-fail/log-syntax-gate.rs | 2 +- .../macro-crate-unexported-macro.rs | 2 +- .../compile-fail/macro-crate-unknown-crate.rs | 2 +- ...s-based-on-type-cyclic-types-issue-4821.rs | 2 +- src/test/compile-fail/mutex-arc-nested.rs | 2 +- src/test/compile-fail/no-capture-arc.rs | 2 +- src/test/compile-fail/no-reuse-move-arc.rs | 2 +- src/test/compile-fail/noexporttypeexe.rs | 2 +- .../once-cant-call-twice-on-heap.rs | 2 +- .../once-cant-call-twice-on-stack.rs | 2 +- ...once-cant-move-out-of-non-once-on-stack.rs | 2 +- src/test/compile-fail/pattern-tyvar-2.rs | 2 +- src/test/compile-fail/pattern-tyvar.rs | 2 +- .../phase-syntax-doesnt-resolve.rs | 2 +- .../private-method-cross-crate.rs | 2 +- .../private-struct-field-cross-crate.rs | 2 +- src/test/compile-fail/private-variant-xc.rs | 2 +- src/test/compile-fail/private_variant_2.rs | 2 +- src/test/compile-fail/qquote-1.rs | 4 +- src/test/compile-fail/qquote-2.rs | 4 +- .../compile-fail/regions-glb-free-free.rs | 2 +- src/test/compile-fail/seq-args.rs | 2 +- src/test/compile-fail/spawn-non-nil-fn.rs | 2 +- .../compile-fail/static-priv-by-default.rs | 2 +- .../compile-fail/static-priv-by-default2.rs | 2 +- src/test/compile-fail/struct-field-privacy.rs | 2 +- .../compile-fail/sync-cond-shouldnt-escape.rs | 2 +- .../sync-rwlock-cond-shouldnt-escape.rs | 2 +- .../sync-rwlock-read-mode-shouldnt-escape.rs | 2 +- ...-rwlock-write-mode-cond-shouldnt-escape.rs | 2 +- .../sync-rwlock-write-mode-shouldnt-escape.rs | 2 +- .../syntax-extension-fourcc-bad-len.rs | 2 +- .../syntax-extension-fourcc-invalid-endian.rs | 2 +- .../syntax-extension-fourcc-non-ascii-str.rs | 2 +- .../syntax-extension-fourcc-non-literal.rs | 2 +- ...ax-extension-fourcc-unsupported-literal.rs | 2 +- .../unresolved-extern-mod-suggestion.rs | 2 +- src/test/compile-fail/unresolved-import.rs | 2 +- src/test/compile-fail/use-from-trait-xc.rs | 2 +- src/test/compile-fail/use-meta-mismatch.rs | 2 +- src/test/compile-fail/use-meta.rc | 2 +- src/test/compile-fail/view-items-at-top.rs | 4 +- src/test/compile-fail/xc-private-method.rs | 2 +- src/test/compile-fail/xc-private-method2.rs | 2 +- .../compile-fail/xcrate-private-by-default.rs | 2 +- src/test/compile-fail/xcrate-unit-struct.rs | 2 +- src/test/pretty/raw-str-nonexpr.rs | 2 +- src/test/run-fail/fail-main.rs | 2 +- src/test/run-fail/fmt-fail.rs | 2 +- src/test/run-fail/for-each-loop-fail.rs | 2 +- src/test/run-fail/issue-2444.rs | 2 +- src/test/run-fail/linked-failure.rs | 2 +- src/test/run-fail/morestack2.rs | 2 +- src/test/run-fail/morestack3.rs | 2 +- src/test/run-fail/morestack4.rs | 2 +- src/test/run-fail/native-failure.rs | 2 +- src/test/run-fail/run-unexported-tests.rs | 2 +- src/test/run-fail/spawnfail.rs | 2 +- .../bootstrap-from-c-with-green/lib.rs | 4 +- .../bootstrap-from-c-with-native/lib.rs | 2 +- src/test/run-make/c-dynamic-dylib/bar.rs | 2 +- src/test/run-make/c-dynamic-rlib/bar.rs | 2 +- src/test/run-make/c-static-dylib/bar.rs | 2 +- src/test/run-make/c-static-rlib/bar.rs | 2 +- src/test/run-make/dylib-chain/m2.rs | 2 +- src/test/run-make/dylib-chain/m3.rs | 2 +- src/test/run-make/dylib-chain/m4.rs | 2 +- src/test/run-make/lto-smoke/main.rs | 2 +- src/test/run-make/mixing-deps/dylib.rs | 2 +- src/test/run-make/mixing-deps/prog.rs | 4 +- src/test/run-make/mixing-libs/dylib.rs | 2 +- src/test/run-make/mixing-libs/prog.rs | 4 +- src/test/run-make/prefer-dylib/foo.rs | 2 +- src/test/run-make/prefer-rlib/foo.rs | 2 +- src/test/run-make/rlib-chain/m2.rs | 2 +- src/test/run-make/rlib-chain/m3.rs | 2 +- src/test/run-make/rlib-chain/m4.rs | 2 +- src/test/run-make/simple-dylib/foo.rs | 2 +- src/test/run-make/simple-rlib/foo.rs | 2 +- src/test/run-make/static-unwinding/main.rs | 2 +- .../macro-crate-outlive-expansion-phase.rs | 2 +- src/test/run-pass-fulldeps/macro-crate.rs | 2 +- src/test/run-pass-fulldeps/qquote.rs | 4 +- src/test/run-pass-fulldeps/quote-tokens.rs | 2 +- .../quote-unused-sp-no-warning.rs | 2 +- .../syntax-extension-fourcc.rs | 2 +- .../run-pass/anon-extern-mod-cross-crate-2.rs | 2 +- .../run-pass/anon_trait_static_method_exe.rs | 2 +- src/test/run-pass/attr-before-view-item.rs | 2 +- src/test/run-pass/attr-before-view-item2.rs | 2 +- src/test/run-pass/auto-encode.rs | 2 +- src/test/run-pass/bind-by-move.rs | 2 +- src/test/run-pass/bitv-perf-test.rs | 2 +- src/test/run-pass/block-arg-call-as.rs | 2 +- .../builtin-superkinds-capabilities-xc.rs | 2 +- .../builtin-superkinds-in-metadata.rs | 2 +- src/test/run-pass/capturing-logging.rs | 2 +- src/test/run-pass/cci_borrow.rs | 2 +- src/test/run-pass/cci_capture_clause.rs | 2 +- src/test/run-pass/cci_impl_exe.rs | 2 +- src/test/run-pass/cci_iter_exe.rs | 2 +- src/test/run-pass/cci_nested_exe.rs | 2 +- src/test/run-pass/cci_no_inline_exe.rs | 2 +- src/test/run-pass/cfg_inner_static.rs | 2 +- .../class-cast-to-trait-cross-crate-2.rs | 2 +- .../class-implement-trait-cross-crate.rs | 2 +- src/test/run-pass/class-method-cross-crate.rs | 2 +- .../run-pass/class-methods-cross-crate.rs | 2 +- .../class-poly-methods-cross-crate.rs | 2 +- src/test/run-pass/classes-cross-crate.rs | 2 +- .../run-pass/classes-simple-cross-crate.rs | 2 +- src/test/run-pass/clone-with-exterior.rs | 2 +- src/test/run-pass/const-cross-crate-const.rs | 2 +- src/test/run-pass/const-cross-crate-extern.rs | 2 +- .../crate-method-reexport-grrrrrrr.rs | 2 +- src/test/run-pass/crateresolve1.rs | 2 +- src/test/run-pass/crateresolve2.rs | 6 +- src/test/run-pass/crateresolve3.rs | 4 +- src/test/run-pass/crateresolve4.rs | 4 +- src/test/run-pass/crateresolve5.rs | 4 +- src/test/run-pass/crateresolve8.rs | 4 +- src/test/run-pass/cross-crate-const-pat.rs | 2 +- .../cross-crate-newtype-struct-pat.rs | 2 +- .../run-pass/deriving-encodable-decodable.rs | 2 +- src/test/run-pass/deriving-global.rs | 4 +- src/test/run-pass/duplicate-use.rs | 2 +- src/test/run-pass/duplicated-external-mods.rs | 2 +- src/test/run-pass/explicit-self-generic.rs | 2 +- src/test/run-pass/explicit_self_xcrate_exe.rs | 2 +- .../extern-calling-convention-test.rs | 2 +- src/test/run-pass/extern-crosscrate.rs | 2 +- src/test/run-pass/extern-foreign-crate.rs | 2 +- src/test/run-pass/extern-mod-ordering-exe.rs | 2 +- src/test/run-pass/extern-mod-syntax.rs | 2 +- src/test/run-pass/float-nan.rs | 2 +- src/test/run-pass/foreign-fn-linkname.rs | 2 +- ...generic-default-type-params-cross-crate.rs | 2 +- src/test/run-pass/getopts_ref.rs | 2 +- src/test/run-pass/glob-std.rs | 6 +- src/test/run-pass/impl-privacy-xc-1.rs | 2 +- src/test/run-pass/impl-privacy-xc-2.rs | 2 +- src/test/run-pass/import-glob-crate.rs | 2 +- src/test/run-pass/infinite-loops.rs | 2 +- src/test/run-pass/inner-static.rs | 2 +- src/test/run-pass/intrinsic-atomics-cc.rs | 2 +- src/test/run-pass/intrinsics-integer.rs | 2 +- src/test/run-pass/invoke-external-foreign.rs | 2 +- src/test/run-pass/issue-10031.rs | 2 +- src/test/run-pass/issue-11224.rs | 2 +- src/test/run-pass/issue-11225-1.rs | 2 +- src/test/run-pass/issue-11225-2.rs | 2 +- src/test/run-pass/issue-2316-c.rs | 2 +- src/test/run-pass/issue-2380-b.rs | 2 +- src/test/run-pass/issue-2383.rs | 2 +- src/test/run-pass/issue-2414-c.rs | 2 +- src/test/run-pass/issue-2472.rs | 2 +- src/test/run-pass/issue-2526-a.rs | 2 +- src/test/run-pass/issue-2631-b.rs | 2 +- src/test/run-pass/issue-2723-b.rs | 2 +- src/test/run-pass/issue-2804.rs | 2 +- src/test/run-pass/issue-2904.rs | 2 +- src/test/run-pass/issue-2989.rs | 2 +- src/test/run-pass/issue-3012-2.rs | 2 +- src/test/run-pass/issue-3424.rs | 2 +- src/test/run-pass/issue-3556.rs | 2 +- src/test/run-pass/issue-3563-3.rs | 2 +- src/test/run-pass/issue-3574.rs | 2 +- src/test/run-pass/issue-3609.rs | 2 +- src/test/run-pass/issue-3979-xcrate.rs | 2 +- src/test/run-pass/issue-4016.rs | 4 +- src/test/run-pass/issue-4036.rs | 4 +- src/test/run-pass/issue-4208.rs | 2 +- src/test/run-pass/issue-4241.rs | 2 +- src/test/run-pass/issue-4545.rs | 2 +- src/test/run-pass/issue-5521.rs | 2 +- src/test/run-pass/issue-6919.rs | 2 +- src/test/run-pass/issue-7178.rs | 2 +- src/test/run-pass/issue-8044.rs | 2 +- src/test/run-pass/issue-8259.rs | 2 +- src/test/run-pass/issue-8401.rs | 2 +- src/test/run-pass/issue-8860.rs | 2 +- src/test/run-pass/issue-9123.rs | 2 +- src/test/run-pass/issue-9188.rs | 2 +- src/test/run-pass/issue-9906.rs | 4 +- src/test/run-pass/issue-9968.rs | 4 +- src/test/run-pass/issue2170exe.rs | 2 +- src/test/run-pass/issue2378c.rs | 4 +- src/test/run-pass/issue_3136_b.rs | 2 +- src/test/run-pass/issue_9155.rs | 2 +- src/test/run-pass/item-attributes.rs | 2 +- src/test/run-pass/kinds-in-metadata.rs | 2 +- src/test/run-pass/linkage-visibility.rs | 4 +- .../log-knows-the-names-of-variants-in-std.rs | 2 +- src/test/run-pass/logging-right-crate.rs | 2 +- src/test/run-pass/lots-a-fail.rs | 2 +- src/test/run-pass/macro-crate-def-only.rs | 2 +- .../run-pass/macro-export-inner-module.rs | 2 +- src/test/run-pass/match-join.rs | 2 +- ...nomorphized-callees-with-ty-params-3314.rs | 2 +- src/test/run-pass/morestack5.rs | 2 +- src/test/run-pass/move-3-unique.rs | 2 +- src/test/run-pass/move-3.rs | 2 +- src/test/run-pass/move-4-unique.rs | 2 +- src/test/run-pass/move-4.rs | 2 +- .../moves-based-on-type-cross-crate.rs | 2 +- src/test/run-pass/mutable-alias-vec.rs | 2 +- src/test/run-pass/native-always-waits.rs | 2 +- src/test/run-pass/nested_item_main.rs | 2 +- src/test/run-pass/newtype-struct-xc-2.rs | 2 +- src/test/run-pass/newtype-struct-xc.rs | 2 +- src/test/run-pass/no-std-xcrate.rs | 2 +- src/test/run-pass/no-std-xcrate2.rs | 2 +- src/test/run-pass/non-boolean-pure-fns.rs | 2 +- src/test/run-pass/once-move-out-on-heap.rs | 2 +- src/test/run-pass/once-move-out-on-stack.rs | 2 +- src/test/run-pass/packed-struct-size-xc.rs | 2 +- .../phase-syntax-link-does-resolve.rs | 2 +- src/test/run-pass/placement-new-arena.rs | 2 +- src/test/run-pass/preempt.rs | 2 +- src/test/run-pass/priv-impl-prim-ty.rs | 2 +- src/test/run-pass/privacy-reexport.rs | 2 +- src/test/run-pass/pub-use-xcrate.rs | 2 +- src/test/run-pass/pub_use_mods_xcrate_exe.rs | 2 +- .../run-pass/reexport-should-still-link.rs | 4 +- .../reexported-static-methods-cross-crate.rs | 2 +- ...-lifetime-static-items-enclosing-scopes.rs | 2 +- src/test/run-pass/regions-mock-tcx.rs | 2 +- src/test/run-pass/rename-directory.rs | 2 +- src/test/run-pass/send-iloop.rs | 2 +- src/test/run-pass/send_str_treemap.rs | 2 +- src/test/run-pass/spawn.rs | 2 +- src/test/run-pass/stat.rs | 2 +- src/test/run-pass/static-fn-inline-xc.rs | 2 +- src/test/run-pass/static-fn-trait-xc.rs | 2 +- .../run-pass/static-function-pointer-xc.rs | 2 +- src/test/run-pass/static-method-xcrate.rs | 2 +- src/test/run-pass/static-mut-xc.rs | 2 +- src/test/run-pass/str-append.rs | 2 +- src/test/run-pass/str-multiline.rs | 2 +- src/test/run-pass/string-self-append.rs | 2 +- .../struct-destructuring-cross-crate.rs | 2 +- src/test/run-pass/struct_variant_xc.rs | 2 +- src/test/run-pass/task-comm-0.rs | 2 +- src/test/run-pass/task-comm-10.rs | 2 +- src/test/run-pass/task-comm-11.rs | 2 +- src/test/run-pass/task-comm-12.rs | 2 +- src/test/run-pass/task-comm-13.rs | 2 +- src/test/run-pass/task-comm-15.rs | 2 +- src/test/run-pass/task-comm-17.rs | 2 +- src/test/run-pass/task-comm-3.rs | 2 +- src/test/run-pass/task-comm-5.rs | 2 +- src/test/run-pass/task-comm-7.rs | 2 +- src/test/run-pass/task-comm-9.rs | 2 +- src/test/run-pass/task-comm-chan-nil.rs | 2 +- src/test/run-pass/task-life-0.rs | 2 +- src/test/run-pass/tempfile.rs | 4 +- src/test/run-pass/terminate-in-initializer.rs | 2 +- src/test/run-pass/test-ignore-cfg.rs | 2 +- src/test/run-pass/test-runner-hides-main.rs | 2 +- src/test/run-pass/threads.rs | 2 +- src/test/run-pass/trait-bounds-in-arc.rs | 2 +- .../run-pass/trait-default-method-xc-2.rs | 4 +- src/test/run-pass/trait-default-method-xc.rs | 2 +- .../run-pass/trait-inheritance-auto-xc-2.rs | 2 +- .../run-pass/trait-inheritance-auto-xc.rs | 2 +- .../trait-inheritance-cross-trait-call-xc.rs | 2 +- src/test/run-pass/trait-inheritance-num.rs | 2 +- src/test/run-pass/trait-inheritance-num2.rs | 2 +- .../trait-inheritance-overloading-xc-exe.rs | 2 +- src/test/run-pass/trait-typedef-cc.rs | 2 +- src/test/run-pass/type-sizes.rs | 2 +- src/test/run-pass/typeid-intrinsic.rs | 4 +- src/test/run-pass/unify-return-ty.rs | 2 +- src/test/run-pass/unwind-box.rs | 2 +- src/test/run-pass/unwind-resource.rs | 2 +- src/test/run-pass/unwind-resource2.rs | 2 +- src/test/run-pass/unwind-unique.rs | 2 +- src/test/run-pass/use-crate-name-alias.rs | 2 +- src/test/run-pass/use.rs | 6 +- src/test/run-pass/use_inline_dtor.rs | 2 +- src/test/run-pass/utf8_chars.rs | 2 +- src/test/run-pass/vec-self-append.rs | 2 +- .../run-pass/xcrate-address-insignificant.rs | 2 +- src/test/run-pass/xcrate-static-addresses.rs | 2 +- .../run-pass/xcrate-trait-lifetime-param.rs | 2 +- src/test/run-pass/xcrate-unit-struct.rs | 2 +- 438 files changed, 682 insertions(+), 685 deletions(-) diff --git a/src/compiletest/compiletest.rs b/src/compiletest/compiletest.rs index 94153c169aca3..15aa68aaebbdf 100644 --- a/src/compiletest/compiletest.rs +++ b/src/compiletest/compiletest.rs @@ -13,8 +13,8 @@ #[allow(non_camel_case_types)]; #[deny(warnings)]; -extern mod extra; -extern mod getopts; +extern crate extra; +extern crate getopts; use std::os; use std::io; diff --git a/src/doc/favicon.inc b/src/doc/favicon.inc index 8dd05620e48f6..b68c58c9b6176 100644 --- a/src/doc/favicon.inc +++ b/src/doc/favicon.inc @@ -1 +1 @@ - \ No newline at end of file + diff --git a/src/doc/guide-runtime.md b/src/doc/guide-runtime.md index 40319c1ec4fab..6d5d90e2617fe 100644 --- a/src/doc/guide-runtime.md +++ b/src/doc/guide-runtime.md @@ -232,7 +232,7 @@ fn main() {} Whereas this program explicitly opts into using a particular runtime ~~~{.rust} -extern mod green; +extern crate green; #[start] fn start(argc: int, argv: **u8) -> int { diff --git a/src/doc/guide-tasks.md b/src/doc/guide-tasks.md index 9ff712df02152..813b61dc8fb39 100644 --- a/src/doc/guide-tasks.md +++ b/src/doc/guide-tasks.md @@ -285,7 +285,7 @@ later. The basic example below illustrates this. ~~~ -# extern mod sync; +# extern crate sync; # fn main() { # fn make_a_sandwich() {}; @@ -310,7 +310,7 @@ Here is another example showing how futures allow you to background computations be distributed on the available cores. ~~~ -# extern mod sync; +# extern crate sync; # use std::vec; fn partial_sum(start: uint) -> f64 { let mut local_sum = 0f64; @@ -346,7 +346,7 @@ Here is a small example showing how to use Arcs. We wish to run concurrently sev a single large vector of floats. Each task needs the full vector to perform its duty. ~~~ -# extern mod sync; +# extern crate sync; # use std::vec; # use std::rand; use sync::Arc; @@ -379,7 +379,7 @@ at the power given as argument and takes the inverse power of this value). The A created by the line ~~~ -# extern mod sync; +# extern crate sync; # use sync::Arc; # use std::vec; # use std::rand; @@ -392,7 +392,7 @@ let numbers_arc=Arc::new(numbers); and a clone of it is sent to each task ~~~ -# extern mod sync; +# extern crate sync; # use sync::Arc; # use std::vec; # use std::rand; @@ -409,7 +409,7 @@ copying only the wrapper and not its contents. Each task recovers the underlying data by ~~~ -# extern mod sync; +# extern crate sync; # use sync::Arc; # use std::vec; # use std::rand; @@ -499,7 +499,7 @@ the string in response. The child terminates when it receives `0`. Here is the function that implements the child task: ~~~ -# extern mod sync; +# extern crate sync; # fn main() { # use sync::DuplexStream; fn stringifier(channel: &DuplexStream<~str, uint>) { @@ -524,7 +524,7 @@ response itself is simply the stringified version of the received value, Here is the code for the parent task: ~~~ -# extern mod sync; +# extern crate sync; # use std::task::spawn; # use sync::DuplexStream; # fn stringifier(channel: &DuplexStream<~str, uint>) { diff --git a/src/doc/guide-testing.md b/src/doc/guide-testing.md index 455c65cef8b7f..e51988565b031 100644 --- a/src/doc/guide-testing.md +++ b/src/doc/guide-testing.md @@ -185,7 +185,7 @@ amount. For example: ~~~ -extern mod extra; +extern crate extra; use std::vec; use extra::test::BenchHarness; @@ -243,7 +243,7 @@ recognize that some calculation has no external effects and remove it entirely. ~~~ -extern mod extra; +extern crate extra; use extra::test::BenchHarness; #[bench] diff --git a/src/doc/po/ja/complement-cheatsheet.md.po b/src/doc/po/ja/complement-cheatsheet.md.po index 77fdddf343def..72ef1d5a0102b 100644 --- a/src/doc/po/ja/complement-cheatsheet.md.po +++ b/src/doc/po/ja/complement-cheatsheet.md.po @@ -273,7 +273,7 @@ msgstr "## タプル" #. type: Plain text #: src/doc/complement-cheatsheet.md:122 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "~~~\n" "struct Foo {\n" @@ -282,7 +282,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" diff --git a/src/doc/po/ja/guide-conditions.md.po b/src/doc/po/ja/guide-conditions.md.po index 1ef53f940e805..a65d6eec4198c 100644 --- a/src/doc/po/ja/guide-conditions.md.po +++ b/src/doc/po/ja/guide-conditions.md.po @@ -79,13 +79,13 @@ msgstr "# 関数" #: src/doc/guide-conditions.md:262 #, fuzzy #| msgid "" -#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello " +#| "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello " #| "\" + world::explore()); } ~~~~" msgid "fn main() {" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" diff --git a/src/doc/po/ja/guide-container.md.po b/src/doc/po/ja/guide-container.md.po index 652338c5fd41f..23e1c7734f0b4 100644 --- a/src/doc/po/ja/guide-container.md.po +++ b/src/doc/po/ja/guide-container.md.po @@ -74,7 +74,7 @@ msgstr "# イントロダクション" #. type: Plain text #: src/doc/guide-container.md:85 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "impl Iterator for ZeroStream {\n" " fn next(&mut self) -> Option {\n" @@ -85,7 +85,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" diff --git a/src/doc/po/ja/guide-ffi.md.po b/src/doc/po/ja/guide-ffi.md.po index e2f24daadce47..3155b9f65053f 100644 --- a/src/doc/po/ja/guide-ffi.md.po +++ b/src/doc/po/ja/guide-ffi.md.po @@ -70,7 +70,7 @@ msgstr "## 最小限の例" #. type: Plain text #: src/doc/guide-ffi.md:323 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "struct RustObject {\n" " a: i32,\n" @@ -79,7 +79,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" diff --git a/src/doc/po/ja/guide-pointers.md.po b/src/doc/po/ja/guide-pointers.md.po index 8cae9a3162701..2b130821c4c9a 100644 --- a/src/doc/po/ja/guide-pointers.md.po +++ b/src/doc/po/ja/guide-pointers.md.po @@ -154,7 +154,7 @@ msgstr "" #: src/doc/guide-pointers.md:141 src/doc/guide-pointers.md:221 #: src/doc/guide-pointers.md:238 src/doc/guide-pointers.md:300 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "~~~rust\n" "struct Point {\n" @@ -164,7 +164,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -222,7 +222,7 @@ msgstr "# データ構造" #. type: Plain text #: src/doc/guide-pointers.md:189 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "~~~rust\n" "enum List {\n" @@ -232,7 +232,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -304,7 +304,7 @@ msgstr "## マネージドボックス" #. type: Plain text #: src/doc/guide-pointers.md:269 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "~~~rust{.ignore}\n" "struct Point {\n" @@ -314,7 +314,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -372,7 +372,7 @@ msgstr "" #. type: Plain text #: src/doc/guide-pointers.md:341 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "struct Point {\n" " x: f32,\n" @@ -381,7 +381,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -402,7 +402,7 @@ msgstr "" #. type: Plain text #: src/doc/guide-pointers.md:378 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "~~~rust{.ignore}\n" "fn main() {\n" @@ -413,7 +413,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -499,7 +499,7 @@ msgstr "" #. type: Plain text #: src/doc/guide-pointers.md:450 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "fn main() {\n" " let x = ~5;\n" @@ -509,7 +509,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -530,7 +530,7 @@ msgstr "" #. type: Plain text #: src/doc/guide-pointers.md:463 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "fn main() {\n" " let x = ~5;\n" @@ -540,14 +540,14 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" #. type: Plain text #: src/doc/guide-pointers.md:477 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "fn main() {\n" " let x = ~5;\n" @@ -557,7 +557,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" diff --git a/src/doc/po/ja/guide-runtime.md.po b/src/doc/po/ja/guide-runtime.md.po index 9c4259fa11335..2e02fe344ebaf 100644 --- a/src/doc/po/ja/guide-runtime.md.po +++ b/src/doc/po/ja/guide-runtime.md.po @@ -83,13 +83,13 @@ msgstr "## 他のクレートの利用" #: src/doc/guide-runtime.md:231 #, fuzzy #| msgid "" -#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello " +#| "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello " #| "\" + world::explore()); } ~~~~" msgid "~~~{.rust} fn main() {} ~~~" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -97,7 +97,7 @@ msgstr "" #: src/doc/guide-runtime.md:236 #, fuzzy #| msgid "~~~~ {.ignore} let foo = 10;" -msgid "~~~{.rust} extern mod green;" +msgid "~~~{.rust} extern crate green;" msgstr "" "~~~~ {.ignore}\n" "let foo = 10;" @@ -106,13 +106,13 @@ msgstr "" #: src/doc/guide-runtime.md:246 #, fuzzy #| msgid "" -#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello " +#| "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello " #| "\" + world::explore()); } ~~~~" msgid "fn main() {} ~~~" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" diff --git a/src/doc/po/ja/guide-testing.md.po b/src/doc/po/ja/guide-testing.md.po index 4a173de1cbf0a..6ec1a4467da86 100644 --- a/src/doc/po/ja/guide-testing.md.po +++ b/src/doc/po/ja/guide-testing.md.po @@ -61,7 +61,7 @@ msgstr "## 最小限の例" #: src/doc/guide-testing.md:131 #, fuzzy #| msgid "~~~~ use std::task::spawn;" -msgid "~~~ extern mod extra; use std::vec;" +msgid "~~~ extern crate extra; use std::vec;" msgstr "" "~~~~\n" "use std::task::spawn;" diff --git a/src/doc/po/ja/rust.md.po b/src/doc/po/ja/rust.md.po index a4b875062fbda..0e96f4db84bf4 100644 --- a/src/doc/po/ja/rust.md.po +++ b/src/doc/po/ja/rust.md.po @@ -310,14 +310,14 @@ msgstr "## 他のクレートの利用" #: src/doc/rust.md:786 #, fuzzy #| msgid "## Using other crates" -msgid "Four examples of `extern mod` declarations:" +msgid "Four examples of `extern crate` declarations:" msgstr "## 他のクレートの利用" #. type: Plain text #: src/doc/rust.md:789 #, fuzzy #| msgid "~~~~ {.ignore} let foo = 10;" -msgid "~~~~ {.ignore} extern mod pcre;" +msgid "~~~~ {.ignore} extern crate pcre;" msgstr "" "~~~~ {.ignore}\n" "let foo = 10;" @@ -365,7 +365,7 @@ msgstr "## 最小限の例" #| msgid "~~~~ {.ignore} let foo = 10;" msgid "" "mod foo {\n" -" extern mod extra;\n" +" extern crate extra;\n" msgstr "" "~~~~ {.ignore}\n" "let foo = 10;" @@ -374,13 +374,13 @@ msgstr "" #: src/doc/rust.md:901 #, fuzzy #| msgid "" -#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello " +#| "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello " #| "\" + world::explore()); } ~~~~" msgid "fn main() {} ~~~~" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -751,7 +751,7 @@ msgstr "# イントロダクション" #. type: Plain text #: src/doc/rust.md:1420 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "struct Circle {\n" " radius: f64,\n" @@ -760,7 +760,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -775,13 +775,13 @@ msgstr "## 本書の表記について" #: src/doc/rust.md:1644 src/doc/rust.md:1665 #, fuzzy #| msgid "" -#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello " +#| "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello " #| "\" + world::explore()); } ~~~~" msgid "# fn main() {} ~~~~" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -866,7 +866,7 @@ msgstr "## 凍結" #. type: Plain text #: src/doc/rust.md:1953 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "~~~~\n" "#[deriving(Eq, Clone)]\n" @@ -878,7 +878,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -1254,7 +1254,7 @@ msgstr "" #. type: Plain text #: src/doc/rust.md:2702 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "while i < 10 {\n" " println!(\"hello\");\n" @@ -1264,7 +1264,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -1306,7 +1306,7 @@ msgstr "## 最小限の例" #. type: Plain text #: src/doc/rust.md:2774 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "for e in v.iter() {\n" " bar(*e);\n" @@ -1315,7 +1315,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -1637,7 +1637,7 @@ msgstr "## 最小限の例" #. type: Plain text #: src/doc/rust.md:3314 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "~~~~\n" "trait Printable {\n" @@ -1646,14 +1646,14 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" #. type: Plain text #: src/doc/rust.md:3318 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "impl Printable for int {\n" " fn to_string(&self) -> ~str { self.to_str() }\n" @@ -1661,14 +1661,14 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" #. type: Plain text #: src/doc/rust.md:3327 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "fn main() {\n" " print(@10 as @Printable);\n" @@ -1677,7 +1677,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -1698,7 +1698,7 @@ msgstr "# クロージャ" #. type: Plain text #: src/doc/rust.md:3359 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "~~~~\n" "trait Printable {\n" @@ -1707,14 +1707,14 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" #. type: Plain text #: src/doc/rust.md:3366 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "impl Printable for ~str {\n" " fn make_string(&self) -> ~str {\n" @@ -1725,7 +1725,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" diff --git a/src/doc/po/ja/tutorial.md.po b/src/doc/po/ja/tutorial.md.po index 9d36cb4d91358..34769b320b7d0 100644 --- a/src/doc/po/ja/tutorial.md.po +++ b/src/doc/po/ja/tutorial.md.po @@ -431,7 +431,7 @@ msgstr "" #. type: Plain text #: src/doc/tutorial.md:136 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "~~~~\n" "fn main() {\n" @@ -441,7 +441,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -634,7 +634,7 @@ msgstr "" #. type: Plain text #: src/doc/tutorial.md:222 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "while count < 10 {\n" " println!(\"count is {}\", count);\n" @@ -644,7 +644,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -1413,7 +1413,7 @@ msgstr "" #. type: Plain text #: src/doc/tutorial.md:602 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "~~~~\n" "struct Point {\n" @@ -1424,7 +1424,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -2187,7 +2187,7 @@ msgstr "# ボックス" #. type: Plain text #: src/doc/tutorial.md:986 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "struct Foo {\n" " a: u32,\n" @@ -2198,7 +2198,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -2312,7 +2312,7 @@ msgstr "例として、シンプルな構造体型の `Point` について考え #. type: Plain text #: src/doc/tutorial.md:1376 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "~~~\n" "struct Point {\n" @@ -2323,7 +2323,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -3688,7 +3688,7 @@ msgstr "" #. type: Plain text #: src/doc/tutorial.md:2110 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "~~~\n" "struct TimeBomb {\n" @@ -3697,7 +3697,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -3735,7 +3735,7 @@ msgstr "" #. type: Plain text #: src/doc/tutorial.md:2135 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "~~~~\n" "trait Printable {\n" @@ -3745,7 +3745,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -3774,7 +3774,7 @@ msgstr "[impls]: #メソッド" #. type: Plain text #: src/doc/tutorial.md:2160 src/doc/tutorial.md:2206 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "impl Printable for ~str {\n" " fn print(&self) { println!(\"{}\", *self) }\n" @@ -3782,7 +3782,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -3821,7 +3821,7 @@ msgstr "## トレイトの実装の導出" #. type: Plain text #: src/doc/tutorial.md:2185 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "impl Printable for bool {\n" " fn print(&self) { println!(\"{:?}\", *self) }\n" @@ -3829,7 +3829,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -3864,7 +3864,7 @@ msgstr "## タプル" #. type: Plain text #: src/doc/tutorial.md:2235 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "~~~~\n" "trait Seq {\n" @@ -3873,14 +3873,14 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" #. type: Plain text #: src/doc/tutorial.md:2240 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "impl Seq for ~[T] {\n" " fn length(&self) -> uint { self.len() }\n" @@ -3889,7 +3889,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -4447,7 +4447,7 @@ msgstr "## クレート" #. type: Plain text #: src/doc/tutorial.md:2554 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "~~~~\n" "// `main.rs`\n" @@ -4458,7 +4458,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -4487,7 +4487,7 @@ msgstr "## 標準ライブラリ" #. type: Plain text #: src/doc/tutorial.md:2587 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "fn main() {\n" " println!(\"Hello farm!\");\n" @@ -4496,7 +4496,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -4510,21 +4510,21 @@ msgstr "## マネージドクロージャ" #. type: Plain text #: src/doc/tutorial.md:2607 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "fn main() {\n" " println!(\"Hello chicken!\");\n" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" #. type: Plain text #: src/doc/tutorial.md:2639 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "fn main() {\n" " println!(\"Hello chicken!\");\n" @@ -4534,7 +4534,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -4573,7 +4573,7 @@ msgstr "# モジュールとクレート" #. type: Plain text #: src/doc/tutorial.md:2719 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "fn main() {\n" " println!(\"Hello farm!\");\n" @@ -4583,7 +4583,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -4653,34 +4653,34 @@ msgstr "" #: src/doc/tutorial.md:2897 #, fuzzy #| msgid "" -#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello " +#| "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello " #| "\" + world::explore()); } ~~~~" msgid "fn main() { cow() } ~~~" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" #. type: Plain text #: src/doc/tutorial.md:2916 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "fn main() {\n" " println!(\"Hello farm!\");\n" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" #. type: Plain text #: src/doc/tutorial.md:2923 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" " // Can now refer to those names directly:\n" " chicken();\n" @@ -4691,7 +4691,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -4699,7 +4699,7 @@ msgstr "" #: src/doc/tutorial.md:2932 #, fuzzy #| msgid "" -#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello " +#| "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello " #| "\" + world::explore()); } ~~~~" msgid "" "~~~{.ignore} // `a.rs` - crate root use b::foo; mod b; fn main() { foo(); } " @@ -4707,7 +4707,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -4715,21 +4715,21 @@ msgstr "" #: src/doc/tutorial.md:2939 #, fuzzy #| msgid "" -#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello " +#| "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello " #| "\" + world::explore()); } ~~~~" msgid "" "~~~{.ignore} // `b.rs` use b::c::bar; pub mod c; pub fn foo() { bar(); } ~~~" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" #. type: Plain text #: src/doc/tutorial.md:2985 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "fn main() {\n" " egg_layer();\n" @@ -4738,7 +4738,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -4752,7 +4752,7 @@ msgstr "# ポインタのデリファレンス" #. type: Plain text #: src/doc/tutorial.md:3014 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "fn main() {\n" " farm::chicken();\n" @@ -4763,7 +4763,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -4778,13 +4778,13 @@ msgstr "## 他のクレートの利用" #: src/doc/tutorial.md:3035 #, fuzzy #| msgid "## Using other crates" -msgid "For that, Rust offers you the `extern mod` declaration:" +msgid "For that, Rust offers you the `extern crate` declaration:" msgstr "## 他のクレートの利用" #. type: Plain text #: src/doc/tutorial.md:3045 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "fn main() {\n" " // The rational number '1/2':\n" @@ -4794,7 +4794,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -4802,7 +4802,7 @@ msgstr "" #: src/doc/tutorial.md:3068 #, fuzzy #| msgid "~~~~ {.ignore} let foo = 10;" -msgid "~~~ extern mod extra;" +msgid "~~~ extern crate extra;" msgstr "" "~~~~ {.ignore}\n" "let foo = 10;" @@ -4810,7 +4810,7 @@ msgstr "" #. type: Plain text #: src/doc/tutorial.md:3081 #, fuzzy, no-wrap -#| msgid "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" +#| msgid "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello \" + world::explore()); } ~~~~" msgid "" "fn main() {\n" " farm::dog();\n" @@ -4820,7 +4820,7 @@ msgid "" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -4835,17 +4835,17 @@ msgstr "## 構造体" #: src/doc/tutorial.md:3123 #, fuzzy #| msgid "" -#| "~~~~ {.ignore} extern mod farm; extern mod my_farm (name = \"farm\", vers " -#| "= \"2.5\"); extern mod my_auxiliary_farm (name = \"farm\", author = \"mjh" +#| "~~~~ {.ignore} extern crate farm; extern crate my_farm (name = \"farm\", vers " +#| "= \"2.5\"); extern crate my_auxiliary_farm (name = \"farm\", author = \"mjh" #| "\"); ~~~~" msgid "" -"~~~~ {.ignore} extern mod farm; extern mod farm = \"farm#2.5\"; extern mod " +"~~~~ {.ignore} extern crate farm; extern crate farm = \"farm#2.5\"; extern crate " "my_farm = \"farm\"; ~~~~" msgstr "" "~~~~ {.ignore}\n" -"extern mod farm;\n" -"extern mod my_farm (name = \"farm\", vers = \"2.5\");\n" -"extern mod my_auxiliary_farm (name = \"farm\", author = \"mjh\");\n" +"extern crate farm;\n" +"extern crate my_farm (name = \"farm\", vers = \"2.5\");\n" +"extern crate my_auxiliary_farm (name = \"farm\", author = \"mjh\");\n" "~~~~" #. type: Plain text @@ -4891,7 +4891,7 @@ msgstr "" #| "~~~~ // world.rs #[link(name = \"world\", vers = \"1.0\")]; pub fn " #| "explore() -> &str { \"world\" } ~~~~" msgid "" -"~~~~ // `world.rs` #[crate_id = \"world#0.42\"]; # extern mod extra; pub fn " +"~~~~ // `world.rs` #[crate_id = \"world#0.42\"]; # extern crate extra; pub fn " "explore() -> &'static str { \"world\" } # fn main() {} ~~~~" msgstr "" "~~~~\n" @@ -4904,15 +4904,15 @@ msgstr "" #: src/doc/tutorial.md:3159 #, fuzzy #| msgid "" -#| "~~~~ {.ignore} // main.rs extern mod world; fn main() { println(~\"hello " +#| "~~~~ {.ignore} // main.rs extern crate world; fn main() { println(~\"hello " #| "\" + world::explore()); } ~~~~" msgid "" -"~~~~ {.ignore} // `main.rs` extern mod world; fn main() { println!(\"hello " +"~~~~ {.ignore} // `main.rs` extern crate world; fn main() { println!(\"hello " "{}\", world::explore()); } ~~~~" msgstr "" "~~~~ {.ignore}\n" "// main.rs\n" -"extern mod world;\n" +"extern crate world;\n" "fn main() { println(~\"hello \" + world::explore()); }\n" "~~~~" @@ -4977,7 +4977,7 @@ msgstr "## 標準ライブラリ" #: src/doc/tutorial.md:3187 #, fuzzy #| msgid "~~~~ {.ignore} let foo = 10;" -msgid "~~~ {.ignore} extern mod std; ~~~" +msgid "~~~ {.ignore} extern crate std; ~~~" msgstr "" "~~~~ {.ignore}\n" "let foo = 10;" diff --git a/src/doc/rust.md b/src/doc/rust.md index fe0fd8bd84d5c..c605ed06ffd1f 100644 --- a/src/doc/rust.md +++ b/src/doc/rust.md @@ -759,7 +759,7 @@ A view item manages the namespace of a module. View items do not define new items, but rather, simply change other items' visibility. There are several kinds of view item: - * [`extern mod` declarations](#extern-mod-declarations) + * [`extern crate` declarations](#extern-mod-declarations) * [`use` declarations](#use-declarations) ##### Extern mod declarations @@ -770,7 +770,7 @@ link_attrs : link_attr [ ',' link_attrs ] + ; link_attr : ident '=' literal ; ~~~~ -An _`extern mod` declaration_ specifies a dependency on an external crate. +An _`extern crate` declaration_ specifies a dependency on an external crate. The external crate is then bound into the declaring scope as the `ident` provided in the `extern_mod_decl`. @@ -782,16 +782,16 @@ against the `crateid` attributes that were declared on the external crate when it was compiled. If no `crateid` is provided, a default `name` attribute is assumed, equal to the `ident` given in the `extern_mod_decl`. -Four examples of `extern mod` declarations: +Four examples of `extern crate` declarations: ~~~~ {.ignore} -extern mod pcre; +extern crate pcre; -extern mod extra; // equivalent to: extern mod extra = "extra"; +extern crate extra; // equivalent to: extern crate extra = "extra"; -extern mod rustextra = "extra"; // linking to 'extra' under another name +extern crate rustextra = "extra"; // linking to 'extra' under another name -extern mod foo = "some/where/rust-foo#foo:1.0"; // a full package ID for external tools +extern crate foo = "some/where/rust-foo#foo:1.0"; // a full package ID for external tools ~~~~ ##### Use declarations @@ -813,7 +813,7 @@ module item. These declarations may appear at the top of [modules](#modules) and *Note*: Unlike in many languages, `use` declarations in Rust do *not* declare linkage dependency with external crates. -Rather, [`extern mod` declarations](#extern-mod-declarations) declare linkage dependencies. +Rather, [`extern crate` declarations](#extern-mod-declarations) declare linkage dependencies. Use declarations support a number of convenient shortcuts: @@ -869,7 +869,7 @@ This also means that top-level module declarations should be at the crate root i of the declared modules within `use` items is desired. It is also possible to use `self` and `super` at the beginning of a `use` item to refer to the current and direct parent modules respectively. All rules regarding accessing declared modules in `use` declarations applies to both module declarations -and `extern mod` declarations. +and `extern crate` declarations. An example of what will and will not work for `use` items: @@ -879,7 +879,7 @@ use foo::extra; // good: foo is at the root of the crate use foo::baz::foobaz; // good: foo is at the root of the crate mod foo { - extern mod extra; + extern crate extra; use foo::extra::time; // good: foo is at crate root // use extra::*; // bad: extra is not at the crate root diff --git a/src/doc/rustdoc.md b/src/doc/rustdoc.md index 72282030fb322..83d1275ab970f 100644 --- a/src/doc/rustdoc.md +++ b/src/doc/rustdoc.md @@ -53,7 +53,7 @@ struct Whizbang; To generate the docs, run `rustdoc universe.rs`. By default, it generates a directory called `doc`, with the documentation for `universe` being in -`doc/universe/index.html`. If you are using other crates with `extern mod`, +`doc/universe/index.html`. If you are using other crates with `extern crate`, rustdoc will even link to them when you use their types, as long as their documentation has already been generated by a previous run of rustdoc, or the crate advertises that its documentation is hosted at a given URL. @@ -176,7 +176,7 @@ rustdoc --test lib.rs --test-args '--ignored' When testing a library, code examples will often show how functions are used, and this code often requires `use`-ing paths from the crate. To accomodate this, -rustdoc will implicitly add `extern mod ;` where `` is the name of +rustdoc will implicitly add `extern crate ;` where `` is the name of the crate being tested to the top of each code example. This means that rustdoc must be able to find a compiled version of the library crate being tested. Extra search paths may be added via the `-L` flag to `rustdoc`. diff --git a/src/doc/tutorial.md b/src/doc/tutorial.md index d620ed0b54f37..bb8d0fee5cae3 100644 --- a/src/doc/tutorial.md +++ b/src/doc/tutorial.md @@ -2581,7 +2581,7 @@ As you can see, your module hierarchy is now three modules deep: There is the cr function, and the module `farm`. The module `farm` also contains two functions and a third module `barn`, which contains a function `hay`. -(In case you already stumbled over `extern mod`: It isn't directly related to a bare `mod`, we'll get to it later. ) +(In case you already stumbled over `extern crate`: It isn't directly related to a bare `mod`, we'll get to it later. ) ## Paths and visibility @@ -3018,10 +3018,10 @@ as there really is no reason to start from scratch each time you start a new pro In Rust terminology, we need a way to refer to other crates. -For that, Rust offers you the `extern mod` declaration: +For that, Rust offers you the `extern crate` declaration: ~~~ -extern mod num; +extern crate num; // `num` ships with Rust (much like `extra`; more details further down). fn main() { @@ -3030,8 +3030,8 @@ fn main() { } ~~~ -Despite its name, `extern mod` is a distinct construct from regular `mod` declarations: -A statement of the form `extern mod foo;` will cause `rustc` to search for the crate `foo`, +Despite its name, `extern crate` is a distinct construct from regular `mod` declarations: +A statement of the form `extern crate foo;` will cause `rustc` to search for the crate `foo`, and if it finds a matching binary it lets you use it from inside your crate. The effect it has on your module hierarchy mirrors aspects of both `mod` and `use`: @@ -3039,19 +3039,19 @@ The effect it has on your module hierarchy mirrors aspects of both `mod` and `us - Like `mod`, it causes `rustc` to actually emit code: The linkage information the binary needs to use the library `foo`. -- But like `use`, all `extern mod` statements that refer to the same library are interchangeable, +- But like `use`, all `extern crate` statements that refer to the same library are interchangeable, as each one really just presents an alias to an external module (the crate root of the library you're linking against). Remember how `use`-statements have to go before local declarations because the latter shadows the former? -Well, `extern mod` statements also have their own rules in that regard: -Both `use` and local declarations can shadow them, so the rule is that `extern mod` has to go in front +Well, `extern crate` statements also have their own rules in that regard: +Both `use` and local declarations can shadow them, so the rule is that `extern crate` has to go in front of both `use` and local declarations. Which can result in something like this: ~~~ -extern mod num; +extern crate num; use farm::dog; use num::rational::Ratio; @@ -3071,7 +3071,7 @@ they model most closely what people expect to shadow. ## Package ids -If you use `extern mod`, per default `rustc` will look for libraries in the library search path (which you can +If you use `extern crate`, per default `rustc` will look for libraries in the library search path (which you can extend with the `-L` switch). ## Crate metadata and settings @@ -3098,14 +3098,14 @@ Therefore, if you plan to compile your crate as a library, you should annotate i # fn farm() {} ~~~~ -You can also specify package ID information in a `extern mod` statement. For -example, these `extern mod` statements would both accept and select the +You can also specify package ID information in a `extern crate` statement. For +example, these `extern crate` statements would both accept and select the crate define above: ~~~~ {.ignore} -extern mod farm; -extern mod farm = "farm#2.5"; -extern mod my_farm = "farm"; +extern crate farm; +extern crate farm = "farm#2.5"; +extern crate my_farm = "farm"; ~~~~ Other crate settings and metadata include things like enabling/disabling certain errors or warnings, @@ -3133,14 +3133,14 @@ We define two crates, and use one of them as a library in the other. ~~~~ // `world.rs` #[crate_id = "world#0.42"]; -# extern mod extra; +# extern crate extra; pub fn explore() -> &'static str { "world" } # fn main() {} ~~~~ ~~~~ {.ignore} // `main.rs` -extern mod world; +extern crate world; fn main() { println!("hello {}", world::explore()); } ~~~~ @@ -3169,7 +3169,7 @@ in the `std` library, which is a crate that ships with Rust. The only magical thing that happens is that `rustc` automatically inserts this line into your crate root: ~~~ {.ignore} -extern mod std; +extern crate std; ~~~ As well as this line into every module body: @@ -3221,7 +3221,7 @@ See the [API documentation][stddoc] for details. Rust ships with crates such as the [extra library], an accumulation of useful things, that are however not important enough to deserve a place in the standard -library. You can link to a library such as `extra` with an `extern mod extra;`. +library. You can link to a library such as `extra` with an `extern crate extra;`. [extra library]: extra/index.html diff --git a/src/doc/version_info.html.template b/src/doc/version_info.html.template index 858e5a35f8741..06008d16f5db0 100644 --- a/src/doc/version_info.html.template +++ b/src/doc/version_info.html.template @@ -3,4 +3,4 @@ Rust VERSION
SHORT_HASH - \ No newline at end of file + diff --git a/src/driver/driver.rs b/src/driver/driver.rs index 25095950e1849..ca462fc7a3922 100644 --- a/src/driver/driver.rs +++ b/src/driver/driver.rs @@ -9,9 +9,9 @@ // except according to those terms. #[cfg(rustdoc)] -extern mod this = "rustdoc"; +extern crate this = "rustdoc"; #[cfg(rustc)] -extern mod this = "rustc"; +extern crate this = "rustc"; fn main() { this::main() } diff --git a/src/etc/combine-tests.py b/src/etc/combine-tests.py index 2c6edaea284f4..c972392a4a0b3 100755 --- a/src/etc/combine-tests.py +++ b/src/etc/combine-tests.py @@ -71,8 +71,8 @@ def scrub(b): """ // AUTO-GENERATED FILE: DO NOT EDIT #[feature(globs, managed_boxes)]; -extern mod extra; -extern mod run_pass_stage2; +extern crate extra; +extern crate run_pass_stage2; use run_pass_stage2::*; use std::io; use std::io::Writer; diff --git a/src/etc/emacs/rust-mode.el b/src/etc/emacs/rust-mode.el index 95732f2553c39..4e1c74c31df91 100644 --- a/src/etc/emacs/rust-mode.el +++ b/src/etc/emacs/rust-mode.el @@ -129,8 +129,7 @@ (defconst rust-mode-keywords '("as" "break" - "continue" - "crate" + "continue" "crate" "do" "else" "enum" "extern" "false" "fn" "for" @@ -368,7 +367,7 @@ With argument, do it that many times. Negative argument -N means move back to Nth preceding end of defun. Assume that this is called after beginning-of-defun. So point is -at the beginning of the defun body. +at the beginning of the defun body. This is written mainly to be used as `end-of-defun-function' for Rust." (interactive "p") diff --git a/src/etc/extract-tests.py b/src/etc/extract-tests.py index 13eadc7988057..2900023ea2b43 100644 --- a/src/etc/extract-tests.py +++ b/src/etc/extract-tests.py @@ -28,7 +28,7 @@ COMMENT_REGEX = re.compile(r'^# ') COMPILER_DIRECTIVE_REGEX = re.compile(r'\#\[(.*)\];') ELLIPSES_REGEX = re.compile(r'\.\.\.') -EXTERN_MOD_REGEX = re.compile(r'\bextern mod extra\b') +EXTERN_CRATE_REGEX = re.compile(r'\bextern crate extra\b') MAIN_FUNCTION_REGEX = re.compile(r'\bfn main\b') TAGS_REGEX = re.compile(r'\.([\w-]*)') @@ -49,12 +49,12 @@ def add_extern_mod(block): if not has_extern_mod(block): - # add `extern mod extra;` after compiler directives + # add `extern crate extra;` after compiler directives directives = [] while len(block) and is_compiler_directive(block[0]): directives.append(block.popleft()) - block.appendleft("\nextern mod extra;\n\n") + block.appendleft("\nextern crate extra;\n\n") block.extendleft(reversed(directives)) return block @@ -112,8 +112,8 @@ def extract_code_fragments(dest_dir, lines): def has_extern_mod(block): - """Checks if a code block has the line `extern mod extra`.""" - find_extern_mod = lambda x: re.search(EXTERN_MOD_REGEX, x) + """Checks if a code block has the line `extern crate extra`.""" + find_extern_mod = lambda x: re.search(EXTERN_CRATE_REGEX, x) return any(imap(find_extern_mod, block)) diff --git a/src/etc/generate-deriving-span-tests.py b/src/etc/generate-deriving-span-tests.py index 7acaa761bb215..ecf58d55576cf 100755 --- a/src/etc/generate-deriving-span-tests.py +++ b/src/etc/generate-deriving-span-tests.py @@ -38,7 +38,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; {error_deriving} struct Error; diff --git a/src/libarena/lib.rs b/src/libarena/lib.rs index 6639e7b3ab7d2..d827e45eddb87 100644 --- a/src/libarena/lib.rs +++ b/src/libarena/lib.rs @@ -22,9 +22,7 @@ #[allow(missing_doc)]; #[feature(managed_boxes)]; -extern mod collections; - -#[cfg(test)] extern mod extra; +extern crate collections; use collections::list::{List, Cons, Nil}; use collections::list; @@ -506,8 +504,9 @@ impl Drop for TypedArena { #[cfg(test)] mod test { + extern crate extra; use super::{Arena, TypedArena}; - use extra::test::BenchHarness; + use self::extra::test::BenchHarness; struct Point { x: int, diff --git a/src/libcollections/lib.rs b/src/libcollections/lib.rs index 417bf47803eaf..e97eeac4f6628 100644 --- a/src/libcollections/lib.rs +++ b/src/libcollections/lib.rs @@ -19,9 +19,8 @@ #[feature(macro_rules, managed_boxes)]; -#[cfg(test)] extern mod extra; - -extern mod serialize; +extern crate serialize; +#[cfg(test)] extern crate extra; // benchmark tests need this pub use bitv::Bitv; pub use btree::BTree; @@ -43,4 +42,4 @@ pub mod lru_cache; pub mod priority_queue; pub mod ringbuf; pub mod smallintmap; -pub mod treemap; \ No newline at end of file +pub mod treemap; diff --git a/src/libextra/json.rs b/src/libextra/json.rs index 3938f1a89942b..a0ca9eca1bda8 100644 --- a/src/libextra/json.rs +++ b/src/libextra/json.rs @@ -59,7 +59,7 @@ the code for these traits: `#[deriving(Decodable, Encodable)]` To encode using Encodable : ```rust -extern mod serialize; +extern crate serialize; use extra::json; use std::io; use serialize::Encodable; @@ -98,7 +98,7 @@ A basic `ToJson` example using a TreeMap of attribute name / attribute value: ```rust -extern mod collections; +extern crate collections; use extra::json; use extra::json::ToJson; @@ -128,7 +128,7 @@ fn main() { To decode a json string using `Decodable` trait : ```rust -extern mod serialize; +extern crate serialize; use serialize::Decodable; #[deriving(Decodable)] @@ -154,7 +154,7 @@ Create a struct called TestStruct1 and serialize and deserialize it to and from using the serialization API, using the derived serialization code. ```rust -extern mod serialize; +extern crate serialize; use extra::json; use serialize::{Encodable, Decodable}; @@ -186,8 +186,8 @@ This example use the ToJson impl to unserialize the json string. Example of `ToJson` trait implementation for TestStruct1. ```rust -extern mod serialize; -extern mod collections; +extern crate serialize; +extern crate collections; use extra::json; use extra::json::ToJson; diff --git a/src/libextra/lib.rs b/src/libextra/lib.rs index c630ac096f622..be7aa216e3024 100644 --- a/src/libextra/lib.rs +++ b/src/libextra/lib.rs @@ -34,10 +34,10 @@ Rust extras are part of the standard Rust distribution. #[deny(non_camel_case_types)]; #[deny(missing_doc)]; -extern mod sync; -extern mod serialize; +extern crate sync; +extern crate serialize; -extern mod collections; +extern crate collections; // Utility modules diff --git a/src/libextra/test.rs b/src/libextra/test.rs index df13538b4bcc3..07327227d8504 100644 --- a/src/libextra/test.rs +++ b/src/libextra/test.rs @@ -15,8 +15,8 @@ // simplest interface possible for representing and running tests // while providing a base that other test frameworks may build off of. -extern mod getopts; -extern mod term; +extern crate getopts; +extern crate term; use json::ToJson; use json; diff --git a/src/libfourcc/lib.rs b/src/libfourcc/lib.rs index e0353cb1fb6b5..270416305dd1c 100644 --- a/src/libfourcc/lib.rs +++ b/src/libfourcc/lib.rs @@ -23,7 +23,7 @@ To load the extension and use it: ```rust,ignore #[phase(syntax)] -extern mod fourcc; +extern crate fourcc; fn main() { let val = fourcc!("\xC0\xFF\xEE!"); @@ -46,7 +46,7 @@ fn main() { #[feature(macro_registrar, managed_boxes)]; -extern mod syntax; +extern crate syntax; use syntax::ast; use syntax::ast::Name; diff --git a/src/libgetopts/lib.rs b/src/libgetopts/lib.rs index 34e09ac1913db..537c2d40c66bf 100644 --- a/src/libgetopts/lib.rs +++ b/src/libgetopts/lib.rs @@ -30,7 +30,7 @@ //! file name following `-o`, and accepts both `-h` and `--help` as optional flags. //! //! ~~~{.rust} -//! extern mod getopts; +//! extern crate getopts; //! use getopts::{optopt,optflag,getopts,OptGroup}; //! use std::os; //! diff --git a/src/libgreen/lib.rs b/src/libgreen/lib.rs index 834bf7951ef1c..8758eb1179ef9 100644 --- a/src/libgreen/lib.rs +++ b/src/libgreen/lib.rs @@ -113,7 +113,7 @@ //! # Starting with libgreen //! //! ```rust -//! extern mod green; +//! extern crate green; //! //! #[start] //! fn start(argc: int, argv: **u8) -> int { green::start(argc, argv, main) } diff --git a/src/libnative/lib.rs b/src/libnative/lib.rs index 4840c561289f9..c28a1175494f9 100644 --- a/src/libnative/lib.rs +++ b/src/libnative/lib.rs @@ -17,7 +17,7 @@ //! # Starting with libnative //! //! ```rust -//! extern mod native; +//! extern crate native; //! //! #[start] //! fn start(argc: int, argv: **u8) -> int { native::start(argc, argv, main) } @@ -30,7 +30,7 @@ //! # Force spawning a native task //! //! ```rust -//! extern mod native; +//! extern crate native; //! //! fn main() { //! // We're not sure whether this main function is run in 1:1 or M:N mode. diff --git a/src/libnum/lib.rs b/src/libnum/lib.rs index 5a5e717363a61..8d5338451bd93 100644 --- a/src/libnum/lib.rs +++ b/src/libnum/lib.rs @@ -15,7 +15,7 @@ #[crate_type = "dylib"]; #[license = "MIT/ASL2"]; -extern mod extra; +extern crate extra; pub mod bigint; pub mod rational; diff --git a/src/librustc/front/test.rs b/src/librustc/front/test.rs index 819f96a391bbf..be9fcf4a1e9ae 100644 --- a/src/librustc/front/test.rs +++ b/src/librustc/front/test.rs @@ -275,7 +275,7 @@ We're going to be building a module that looks more or less like: mod __test { #[!resolve_unexported] - extern mod extra (name = "extra", vers = "..."); + extern crate extra (name = "extra", vers = "..."); fn main() { #[main]; extra::test::test_main_static(::os::args(), tests) diff --git a/src/librustc/lib.rs b/src/librustc/lib.rs index 05087581fd73a..0d615fe19928b 100644 --- a/src/librustc/lib.rs +++ b/src/librustc/lib.rs @@ -31,14 +31,14 @@ This API is completely unstable and subject to change. #[allow(unknown_features)]; // Note: remove it after a snapshot. #[feature(quote)]; -extern mod extra; -extern mod flate; -extern mod arena; -extern mod syntax; -extern mod serialize; -extern mod sync; -extern mod getopts; -extern mod collections; +extern crate extra; +extern crate flate; +extern crate arena; +extern crate syntax; +extern crate serialize; +extern crate sync; +extern crate getopts; +extern crate collections; use back::link; use driver::session; diff --git a/src/librustc/metadata/creader.rs b/src/librustc/metadata/creader.rs index a80ac38e8ae05..901e8982c83d2 100644 --- a/src/librustc/metadata/creader.rs +++ b/src/librustc/metadata/creader.rs @@ -169,7 +169,7 @@ fn extract_crate_info(i: &ast::ViewItem) -> Option { match i.node { ast::ViewItemExternMod(ident, ref path_opt, id) => { let ident = token::get_ident(ident); - debug!("resolving extern mod stmt. ident: {:?} path_opt: {:?}", + debug!("resolving extern crate stmt. ident: {:?} path_opt: {:?}", ident, path_opt); let (name, version) = match *path_opt { Some((ref path_str, _)) => { diff --git a/src/librustc/metadata/cstore.rs b/src/librustc/metadata/cstore.rs index 33625000e4ad0..4febde6d443e0 100644 --- a/src/librustc/metadata/cstore.rs +++ b/src/librustc/metadata/cstore.rs @@ -69,7 +69,7 @@ pub struct CStore { intr: @IdentInterner } -// Map from NodeId's of local extern mod statements to crate numbers +// Map from NodeId's of local extern crate statements to crate numbers type extern_mod_crate_map = HashMap; impl CStore { diff --git a/src/librustc/middle/resolve.rs b/src/librustc/middle/resolve.rs index cb9e772dcea08..1d28c781ea0c8 100644 --- a/src/librustc/middle/resolve.rs +++ b/src/librustc/middle/resolve.rs @@ -418,7 +418,7 @@ struct Module { imports: RefCell<~[@ImportDirective]>, // The external module children of this node that were declared with - // `extern mod`. + // `extern crate`. external_module_children: RefCell>, // The anonymous children of this node. Anonymous children are pseudo- @@ -2679,7 +2679,7 @@ impl Resolver { }; self.resolve_error(span, format!("unresolved import. maybe \ - a missing `extern mod \ + a missing `extern crate \ {}`?", segment_name)); return Failed; diff --git a/src/librustdoc/html/render.rs b/src/librustdoc/html/render.rs index 10b2287793614..c7c4aae35e3f3 100644 --- a/src/librustdoc/html/render.rs +++ b/src/librustdoc/html/render.rs @@ -1021,7 +1021,7 @@ fn item_module(w: &mut Writer, cx: &Context, clean::ViewItemItem(ref item) => { match item.inner { clean::ExternMod(ref name, ref src, _) => { - if_ok!(write!(w, "extern mod {}", + if_ok!(write!(w, "extern crate {}", name.as_slice())); match *src { Some(ref src) => if_ok!(write!(w, " = \"{}\"", diff --git a/src/librustdoc/lib.rs b/src/librustdoc/lib.rs index f30e6309f38ab..e9072fb37bb95 100644 --- a/src/librustdoc/lib.rs +++ b/src/librustdoc/lib.rs @@ -15,13 +15,13 @@ #[feature(globs, struct_variant, managed_boxes)]; -extern mod syntax; -extern mod rustc; -extern mod extra; -extern mod serialize; -extern mod sync; -extern mod getopts; -extern mod collections; +extern crate syntax; +extern crate rustc; +extern crate extra; +extern crate serialize; +extern crate sync; +extern crate getopts; +extern crate collections; use std::local_data; use std::io; diff --git a/src/librustdoc/test.rs b/src/librustdoc/test.rs index 9f8261b4449b6..4b32cdb77eabd 100644 --- a/src/librustdoc/test.rs +++ b/src/librustdoc/test.rs @@ -144,10 +144,10 @@ fn maketest(s: &str, cratename: &str) -> ~str { #[allow(unused_variable, dead_assignment, unused_mut, attribute_usage, dead_code)]; "; if s.contains("extra") { - prog.push_str("extern mod extra;\n"); + prog.push_str("extern crate extra;\n"); } if s.contains(cratename) { - prog.push_str(format!("extern mod {};\n", cratename)); + prog.push_str(format!("extern crate {};\n", cratename)); } if s.contains("fn main") { prog.push_str(s); diff --git a/src/librustuv/lib.rs b/src/librustuv/lib.rs index 8c263c5e5f738..e44f65296f5cc 100644 --- a/src/librustuv/lib.rs +++ b/src/librustuv/lib.rs @@ -42,7 +42,7 @@ via `close` and `delete` methods. #[feature(macro_rules)]; #[deny(unused_result, unused_must_use)]; -#[cfg(test)] extern mod green; +#[cfg(test)] extern crate green; use std::cast; use std::io; diff --git a/src/libserialize/base64.rs b/src/libserialize/base64.rs index c22eefdb33020..918c5e85857db 100644 --- a/src/libserialize/base64.rs +++ b/src/libserialize/base64.rs @@ -63,7 +63,7 @@ impl<'a> ToBase64 for &'a [u8] { * # Example * * ```rust - * extern mod serialize; + * extern crate serialize; * use serialize::base64::{ToBase64, STANDARD}; * * fn main () { @@ -189,7 +189,7 @@ impl<'a> FromBase64 for &'a str { * This converts a string literal to base64 and back. * * ```rust - * extern mod serialize; + * extern crate serialize; * use serialize::base64::{ToBase64, FromBase64, STANDARD}; * use std::str; * diff --git a/src/libserialize/hex.rs b/src/libserialize/hex.rs index 409bf4af80992..08a3dda854e3a 100644 --- a/src/libserialize/hex.rs +++ b/src/libserialize/hex.rs @@ -28,7 +28,7 @@ impl<'a> ToHex for &'a [u8] { * # Example * * ```rust - * extern mod serialize; + * extern crate serialize; * use serialize::hex::ToHex; * * fn main () { @@ -89,7 +89,7 @@ impl<'a> FromHex for &'a str { * This converts a string literal to hexadecimal and back. * * ```rust - * extern mod serialize; + * extern crate serialize; * use serialize::hex::{FromHex, ToHex}; * use std::str; * diff --git a/src/libserialize/lib.rs b/src/libserialize/lib.rs index 3b71b2237b176..7a4b1cff6e47c 100644 --- a/src/libserialize/lib.rs +++ b/src/libserialize/lib.rs @@ -24,7 +24,7 @@ Core encoding and decoding interfaces. // test harness access #[cfg(test)] -extern mod extra; +extern crate extra; pub use self::serialize::{Decoder, Encoder, Decodable, Encodable, DecoderHelpers, EncoderHelpers}; diff --git a/src/libstd/lib.rs b/src/libstd/lib.rs index e0666ef417927..4452482b7e8ce 100644 --- a/src/libstd/lib.rs +++ b/src/libstd/lib.rs @@ -30,7 +30,7 @@ //! `std` is imported at the topmost level of every crate by default, as //! if the first line of each crate was //! -//! extern mod std; +//! extern crate std; //! //! This means that the contents of std can be accessed from any context //! with the `std::` path prefix, as in `use std::vec`, `use std::task::spawn`, @@ -64,15 +64,15 @@ // When testing libstd, bring in libuv as the I/O backend so tests can print // things and all of the std::io tests have an I/O interface to run on top // of -#[cfg(test)] extern mod rustuv = "rustuv"; -#[cfg(test)] extern mod native = "native"; -#[cfg(test)] extern mod green = "green"; +#[cfg(test)] extern crate rustuv = "rustuv"; +#[cfg(test)] extern crate native = "native"; +#[cfg(test)] extern crate green = "green"; // Make extra accessible for benchmarking -#[cfg(test)] extern mod extra = "extra"; +#[cfg(test)] extern crate extra = "extra"; // Make std testable by not duplicating lang items. See #2912 -#[cfg(test)] extern mod realstd = "std"; +#[cfg(test)] extern crate realstd = "std"; #[cfg(test)] pub use kinds = realstd::kinds; #[cfg(test)] pub use ops = realstd::ops; #[cfg(test)] pub use cmp = realstd::cmp; diff --git a/src/libsync/sync/mutex.rs b/src/libsync/sync/mutex.rs index 3726528a5e9c8..8489773bd8814 100644 --- a/src/libsync/sync/mutex.rs +++ b/src/libsync/sync/mutex.rs @@ -495,7 +495,7 @@ impl Drop for Mutex { #[cfg(test)] mod test { - extern mod native; + extern crate native; use super::{Mutex, StaticMutex, MUTEX_INIT}; #[test] diff --git a/src/libsyntax/ast.rs b/src/libsyntax/ast.rs index 132cb396ddd39..a3025d394dab5 100644 --- a/src/libsyntax/ast.rs +++ b/src/libsyntax/ast.rs @@ -1058,7 +1058,7 @@ pub enum ViewItem_ { // ident: name used to refer to this crate in the code // optional (InternedString,StrStyle): if present, this is a location // (containing arbitrary characters) from which to fetch the crate sources - // For example, extern mod whatever = "github.com/mozilla/rust" + // For example, extern crate whatever = "github.com/mozilla/rust" ViewItemExternMod(Ident, Option<(InternedString,StrStyle)>, NodeId), ViewItemUse(~[@ViewPath]), } diff --git a/src/libsyntax/lib.rs b/src/libsyntax/lib.rs index 78e40a795db1f..3cbdad9a71d7e 100644 --- a/src/libsyntax/lib.rs +++ b/src/libsyntax/lib.rs @@ -32,10 +32,10 @@ This API is completely unstable and subject to change. #[deny(non_camel_case_types)]; -#[cfg(test)] extern mod extra; -extern mod serialize; -extern mod term; -extern mod collections; +#[cfg(test)] extern crate extra; +extern crate serialize; +extern crate term; +extern crate collections; pub mod util { pub mod interner; diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs index f602925140b65..6cde22fad107c 100644 --- a/src/libsyntax/parse/parser.rs +++ b/src/libsyntax/parse/parser.rs @@ -4528,7 +4528,7 @@ impl Parser { // parse one of the items or view items allowed by the // flags; on failure, return IoviNone. // NB: this function no longer parses the items inside an - // extern mod. + // extern crate. fn parse_item_or_view_item(&mut self, attrs: ~[Attribute], macros_allowed: bool) @@ -4567,10 +4567,10 @@ impl Parser { if next_is_mod || self.eat_keyword(keywords::Crate) { if next_is_mod { - self.span_err(self.span, - format!("`extern mod` is obsolete, use \ - `extern crate` instead \ - to refer to external crates.")) + self.span_err(mk_sp(lo, self.last_span.hi), + format!("`extern mod` is obsolete, use \ + `extern crate` instead \ + to refer to external crates.")) } return self.parse_item_extern_crate(lo, visibility, attrs); } @@ -4970,7 +4970,7 @@ impl Parser { let mut items = ~[]; // I think this code would probably read better as a single - // loop with a mutable three-state-variable (for extern mods, + // loop with a mutable three-state-variable (for extern crates, // view items, and regular items) ... except that because // of macros, I'd like to delay that entire check until later. loop { @@ -4986,12 +4986,12 @@ impl Parser { IoviViewItem(view_item) => { match view_item.node { ViewItemUse(..) => { - // `extern mod` must precede `use`. + // `extern crate` must precede `use`. extern_mod_allowed = false; } ViewItemExternMod(..) if !extern_mod_allowed => { self.span_err(view_item.span, - "\"extern mod\" declarations are not allowed here"); + "\"extern crate\" declarations are not allowed here"); } ViewItemExternMod(..) => {} } @@ -5019,7 +5019,7 @@ impl Parser { IoviViewItem(view_item) => { attrs = self.parse_outer_attributes(); self.span_err(view_item.span, - "`use` and `extern mod` declarations must precede items"); + "`use` and `extern crate` declarations must precede items"); } IoviItem(item) => { attrs = self.parse_outer_attributes(); @@ -5059,7 +5059,7 @@ impl Parser { IoviViewItem(view_item) => { // I think this can't occur: self.span_err(view_item.span, - "`use` and `extern mod` declarations must precede items"); + "`use` and `extern crate` declarations must precede items"); } IoviItem(item) => { // FIXME #5668: this will occur for a macro invocation: diff --git a/src/libsyntax/print/pprust.rs b/src/libsyntax/print/pprust.rs index bb2f345ac2883..ceaa7d1a9a151 100644 --- a/src/libsyntax/print/pprust.rs +++ b/src/libsyntax/print/pprust.rs @@ -2061,7 +2061,7 @@ pub fn print_view_item(s: &mut State, item: &ast::ViewItem) -> io::IoResult<()> if_ok!(print_visibility(s, item.vis)); match item.node { ast::ViewItemExternMod(id, ref optional_path, _) => { - if_ok!(head(s, "extern mod")); + if_ok!(head(s, "extern crate")); if_ok!(print_ident(s, id)); for &(ref p, style) in optional_path.iter() { if_ok!(space(&mut s.s)); diff --git a/src/libuuid/lib.rs b/src/libuuid/lib.rs index 36b267c7eb741..180838d41325c 100644 --- a/src/libuuid/lib.rs +++ b/src/libuuid/lib.rs @@ -61,8 +61,8 @@ Examples of string representations: // test harness access #[cfg(test)] -extern mod extra; -extern mod serialize; +extern crate extra; +extern crate serialize; use std::str; use std::vec; diff --git a/src/snapshots.txt b/src/snapshots.txt index 88966a618358c..f3011aaea10b9 100644 --- a/src/snapshots.txt +++ b/src/snapshots.txt @@ -2,8 +2,8 @@ S 2014-02-14 18477ac freebsd-x86_64 102df7dfab2a1c59d9e2f16a3f02f368310dd022 linux-i386 fcf5891e9b3c7c9ef5ee5ea37e62089346099425 linux-x86_64 d7c2df185fd2e25b4b8f5b2caad277b5ba664b81 - macos-i386 - macos-x86_64 + macos-i386 c15faa408339ceebbb68e952e9bf7f2624ceb9e0 + macos-x86_64 445c6759db5e69250b8a8631ea7751d1474e4250 winnt-i386 f78a892f47627f34233e44c2ff4a00b68063a2ce S 2014-02-12 c62f6ce diff --git a/src/test/auxiliary/crateresolve4b-1.rs b/src/test/auxiliary/crateresolve4b-1.rs index c80fb8ee9e965..aa263f34841bb 100644 --- a/src/test/auxiliary/crateresolve4b-1.rs +++ b/src/test/auxiliary/crateresolve4b-1.rs @@ -13,6 +13,6 @@ #[crate_id="crateresolve4b#0.1"]; #[crate_type = "lib"]; -extern mod crateresolve4a = "crateresolve4a#0.2"; +extern crate crateresolve4a = "crateresolve4a#0.2"; pub fn f() -> int { crateresolve4a::g() } diff --git a/src/test/auxiliary/crateresolve4b-2.rs b/src/test/auxiliary/crateresolve4b-2.rs index 019b6047e63dd..e72a6cb163f32 100644 --- a/src/test/auxiliary/crateresolve4b-2.rs +++ b/src/test/auxiliary/crateresolve4b-2.rs @@ -13,6 +13,6 @@ #[crate_id="crateresolve4b#0.2"]; #[crate_type = "lib"]; -extern mod crateresolve4a = "crateresolve4a#0.1"; +extern crate crateresolve4a = "crateresolve4a#0.1"; pub fn g() -> int { crateresolve4a::f() } diff --git a/src/test/auxiliary/crateresolve7x.rs b/src/test/auxiliary/crateresolve7x.rs index 6b85d28b2889b..5cf5c6d178d94 100644 --- a/src/test/auxiliary/crateresolve7x.rs +++ b/src/test/auxiliary/crateresolve7x.rs @@ -14,11 +14,11 @@ // These both have the same version but differ in other metadata pub mod a { - extern mod cr_1 (name = "crateresolve_calories", vers = "0.1", calories="100"); + extern crate cr_1 (name = "crateresolve_calories", vers = "0.1", calories="100"); pub fn f() -> int { cr_1::f() } } pub mod b { - extern mod cr_2 (name = "crateresolve_calories", vers = "0.1", calories="200"); + extern crate cr_2 (name = "crateresolve_calories", vers = "0.1", calories="200"); pub fn f() -> int { cr_2::f() } } diff --git a/src/test/auxiliary/issue-2414-b.rs b/src/test/auxiliary/issue-2414-b.rs index 054e0bf7c3229..177b735ead7a1 100644 --- a/src/test/auxiliary/issue-2414-b.rs +++ b/src/test/auxiliary/issue-2414-b.rs @@ -13,4 +13,4 @@ #[crate_id="b#0.1"]; #[crate_type = "lib"]; -extern mod a; +extern crate a; diff --git a/src/test/auxiliary/issue-2526.rs b/src/test/auxiliary/issue-2526.rs index e932a9c29ea6a..701c9f643ff47 100644 --- a/src/test/auxiliary/issue-2526.rs +++ b/src/test/auxiliary/issue-2526.rs @@ -11,7 +11,7 @@ #[crate_id="issue_2526#0.2"]; #[crate_type = "lib"]; -extern mod extra; +extern crate extra; struct arc_destruct { _data: int, diff --git a/src/test/auxiliary/issue-2631-a.rs b/src/test/auxiliary/issue-2631-a.rs index 15dde899ce374..5c5a80e5d0023 100644 --- a/src/test/auxiliary/issue-2631-a.rs +++ b/src/test/auxiliary/issue-2631-a.rs @@ -12,7 +12,7 @@ #[crate_id="req"]; #[crate_type = "lib"]; -extern mod extra; +extern crate extra; use std::cell::RefCell; use std::hashmap::HashMap; diff --git a/src/test/auxiliary/issue-9906.rs b/src/test/auxiliary/issue-9906.rs index 7d80c5b937eea..d1a6755c1e941 100644 --- a/src/test/auxiliary/issue-9906.rs +++ b/src/test/auxiliary/issue-9906.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -// ignore-fast windows doesn't like extern mod +// ignore-fast windows doesn't like extern crate // aux-build:issue-9906.rs pub use other::FooBar; diff --git a/src/test/auxiliary/issue2378b.rs b/src/test/auxiliary/issue2378b.rs index 2931245bb12bd..1ec6ab906968f 100644 --- a/src/test/auxiliary/issue2378b.rs +++ b/src/test/auxiliary/issue2378b.rs @@ -10,7 +10,7 @@ #[crate_type = "lib"]; -extern mod issue2378a; +extern crate issue2378a; use issue2378a::maybe; diff --git a/src/test/auxiliary/issue_2242_c.rs b/src/test/auxiliary/issue_2242_c.rs index 4008402441b5d..077f395021730 100644 --- a/src/test/auxiliary/issue_2242_c.rs +++ b/src/test/auxiliary/issue_2242_c.rs @@ -11,7 +11,7 @@ #[crate_id="c#0.1"]; #[crate_type = "lib"]; -extern mod a; +extern crate a; use a::to_strz; diff --git a/src/test/auxiliary/issue_2316_b.rs b/src/test/auxiliary/issue_2316_b.rs index 92c20e8d9e39b..36af01fe6c600 100644 --- a/src/test/auxiliary/issue_2316_b.rs +++ b/src/test/auxiliary/issue_2316_b.rs @@ -11,7 +11,7 @@ #[allow(unused_imports)]; #[feature(globs)]; -extern mod issue_2316_a; +extern crate issue_2316_a; pub mod cloth { use issue_2316_a::*; diff --git a/src/test/auxiliary/macro_crate_outlive_expansion_phase.rs b/src/test/auxiliary/macro_crate_outlive_expansion_phase.rs index eecbb325630d3..1a0fb8fe62990 100644 --- a/src/test/auxiliary/macro_crate_outlive_expansion_phase.rs +++ b/src/test/auxiliary/macro_crate_outlive_expansion_phase.rs @@ -12,7 +12,7 @@ #[feature(macro_registrar)]; -extern mod syntax; +extern crate syntax; use std::any::Any; use std::local_data; diff --git a/src/test/auxiliary/macro_crate_test.rs b/src/test/auxiliary/macro_crate_test.rs index 2867e0f814306..b8baffcfea5fc 100644 --- a/src/test/auxiliary/macro_crate_test.rs +++ b/src/test/auxiliary/macro_crate_test.rs @@ -12,7 +12,7 @@ #[feature(globs, macro_registrar, macro_rules, quote)]; -extern mod syntax; +extern crate syntax; use syntax::ast::{Name, TokenTree}; use syntax::codemap::Span; diff --git a/src/test/auxiliary/pub_use_xcrate2.rs b/src/test/auxiliary/pub_use_xcrate2.rs index ce839daa3a09b..d59d7f2a6136c 100644 --- a/src/test/auxiliary/pub_use_xcrate2.rs +++ b/src/test/auxiliary/pub_use_xcrate2.rs @@ -8,6 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod pub_use_xcrate1; +extern crate pub_use_xcrate1; pub use pub_use_xcrate1::Foo; diff --git a/src/test/auxiliary/trait_default_method_xc_aux_2.rs b/src/test/auxiliary/trait_default_method_xc_aux_2.rs index 145f84e558fb8..6a8c03ec6ad34 100644 --- a/src/test/auxiliary/trait_default_method_xc_aux_2.rs +++ b/src/test/auxiliary/trait_default_method_xc_aux_2.rs @@ -10,7 +10,7 @@ // aux-build:trait_default_method_xc_aux.rs -extern mod aux = "trait_default_method_xc_aux"; +extern crate aux = "trait_default_method_xc_aux"; use aux::A; pub struct a_struct { x: int } diff --git a/src/test/bench/core-map.rs b/src/test/bench/core-map.rs index ed3874b1a6fcd..61b3ccd1f54f6 100644 --- a/src/test/bench/core-map.rs +++ b/src/test/bench/core-map.rs @@ -8,8 +8,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; -extern mod collections; +extern crate extra; +extern crate collections; use extra::time; use collections::TreeMap; diff --git a/src/test/bench/core-set.rs b/src/test/bench/core-set.rs index 2d63a6a241ea0..41c48d92692a5 100644 --- a/src/test/bench/core-set.rs +++ b/src/test/bench/core-set.rs @@ -10,8 +10,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; -extern mod collections; +extern crate extra; +extern crate collections; use collections::bitv::BitvSet; use collections::TreeSet; diff --git a/src/test/bench/core-std.rs b/src/test/bench/core-std.rs index 743472af5ce3f..9c29b69117396 100644 --- a/src/test/bench/core-std.rs +++ b/src/test/bench/core-std.rs @@ -12,7 +12,7 @@ #[feature(macro_rules)]; -extern mod extra; +extern crate extra; use extra::time::precise_time_s; use std::mem::swap; diff --git a/src/test/bench/msgsend-pipes-shared.rs b/src/test/bench/msgsend-pipes-shared.rs index b766be88d2309..ae1ae0a436775 100644 --- a/src/test/bench/msgsend-pipes-shared.rs +++ b/src/test/bench/msgsend-pipes-shared.rs @@ -18,7 +18,7 @@ // different scalability characteristics compared to the select // version. -extern mod extra; +extern crate extra; use std::comm; use std::os; diff --git a/src/test/bench/msgsend-pipes.rs b/src/test/bench/msgsend-pipes.rs index 89e0bcf332638..ca06e96f0c0ee 100644 --- a/src/test/bench/msgsend-pipes.rs +++ b/src/test/bench/msgsend-pipes.rs @@ -14,7 +14,7 @@ // // I *think* it's the same, more or less. -extern mod extra; +extern crate extra; use std::os; use std::task; diff --git a/src/test/bench/msgsend-ring-mutex-arcs.rs b/src/test/bench/msgsend-ring-mutex-arcs.rs index 4b505ec811762..5dcccf8d861b6 100644 --- a/src/test/bench/msgsend-ring-mutex-arcs.rs +++ b/src/test/bench/msgsend-ring-mutex-arcs.rs @@ -15,8 +15,8 @@ // This also serves as a pipes test, because Arcs are implemented with pipes. -extern mod extra; -extern mod sync; +extern crate extra; +extern crate sync; use sync::Arc; use sync::MutexArc; diff --git a/src/test/bench/msgsend-ring-rw-arcs.rs b/src/test/bench/msgsend-ring-rw-arcs.rs index 23b4f00b280da..3d619f2e31381 100644 --- a/src/test/bench/msgsend-ring-rw-arcs.rs +++ b/src/test/bench/msgsend-ring-rw-arcs.rs @@ -15,8 +15,8 @@ // This also serves as a pipes test, because Arcs are implemented with pipes. -extern mod extra; -extern mod sync; +extern crate extra; +extern crate sync; use sync::RWArc; use sync::Future; diff --git a/src/test/bench/rt-messaging-ping-pong.rs b/src/test/bench/rt-messaging-ping-pong.rs index b42644f39cb30..0cecb5d752724 100644 --- a/src/test/bench/rt-messaging-ping-pong.rs +++ b/src/test/bench/rt-messaging-ping-pong.rs @@ -17,7 +17,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use std::os; use std::uint; diff --git a/src/test/bench/rt-parfib.rs b/src/test/bench/rt-parfib.rs index 59f5afa47dafd..0512c2a3c967c 100644 --- a/src/test/bench/rt-parfib.rs +++ b/src/test/bench/rt-parfib.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use std::os; use std::uint; diff --git a/src/test/bench/rt-spawn-rate.rs b/src/test/bench/rt-spawn-rate.rs index 20ecee5499fdd..40e6a0a7beda2 100644 --- a/src/test/bench/rt-spawn-rate.rs +++ b/src/test/bench/rt-spawn-rate.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use std::task::spawn; use std::os; diff --git a/src/test/bench/shootout-ackermann.rs b/src/test/bench/shootout-ackermann.rs index a7f86b01b3fff..d308ed6a7d1d7 100644 --- a/src/test/bench/shootout-ackermann.rs +++ b/src/test/bench/shootout-ackermann.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use std::os; diff --git a/src/test/bench/shootout-binarytrees.rs b/src/test/bench/shootout-binarytrees.rs index c0e22f207b8f9..18df07868727e 100644 --- a/src/test/bench/shootout-binarytrees.rs +++ b/src/test/bench/shootout-binarytrees.rs @@ -8,8 +8,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod sync; -extern mod arena; +extern crate sync; +extern crate arena; use std::iter::range_step; use sync::Future; diff --git a/src/test/bench/shootout-chameneos-redux.rs b/src/test/bench/shootout-chameneos-redux.rs index 5c237b306fbd8..a6bbea0ac14da 100644 --- a/src/test/bench/shootout-chameneos-redux.rs +++ b/src/test/bench/shootout-chameneos-redux.rs @@ -10,7 +10,7 @@ // chameneos -extern mod extra; +extern crate extra; use std::option; use std::os; diff --git a/src/test/bench/shootout-fibo.rs b/src/test/bench/shootout-fibo.rs index d7a9dd86f4ddd..4a4b2e8e875ca 100644 --- a/src/test/bench/shootout-fibo.rs +++ b/src/test/bench/shootout-fibo.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use std::os; diff --git a/src/test/bench/shootout-k-nucleotide-pipes.rs b/src/test/bench/shootout-k-nucleotide-pipes.rs index 6f7630ebe8ac7..737e5c98214c9 100644 --- a/src/test/bench/shootout-k-nucleotide-pipes.rs +++ b/src/test/bench/shootout-k-nucleotide-pipes.rs @@ -13,7 +13,7 @@ // ignore-pretty the `let to_child` line gets an extra newline // multi tasking k-nucleotide -extern mod extra; +extern crate extra; use std::cmp::Ord; use std::comm; diff --git a/src/test/bench/shootout-k-nucleotide.rs b/src/test/bench/shootout-k-nucleotide.rs index bdad46bad2e80..9190ff69347eb 100644 --- a/src/test/bench/shootout-k-nucleotide.rs +++ b/src/test/bench/shootout-k-nucleotide.rs @@ -10,7 +10,7 @@ // ignore-test -extern mod extra; +extern crate extra; use std::cast::transmute; use std::i32::range; diff --git a/src/test/bench/shootout-pfib.rs b/src/test/bench/shootout-pfib.rs index 7f4fd3cf94ce1..48aaa7d5b0ab0 100644 --- a/src/test/bench/shootout-pfib.rs +++ b/src/test/bench/shootout-pfib.rs @@ -18,8 +18,8 @@ */ -extern mod extra; -extern mod getopts; +extern crate extra; +extern crate getopts; use extra::time; use std::os; diff --git a/src/test/bench/shootout-pidigits.rs b/src/test/bench/shootout-pidigits.rs index 33f20cf0d1f9b..93ef2b7bb8251 100644 --- a/src/test/bench/shootout-pidigits.rs +++ b/src/test/bench/shootout-pidigits.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod num; +extern crate num; use std::from_str::FromStr; use std::num::One; diff --git a/src/test/bench/shootout-spectralnorm.rs b/src/test/bench/shootout-spectralnorm.rs index a6e6713e137b1..02b3cfae1f4fd 100644 --- a/src/test/bench/shootout-spectralnorm.rs +++ b/src/test/bench/shootout-spectralnorm.rs @@ -10,7 +10,7 @@ // ignore-test arcs no longer unwrap -extern mod sync; +extern crate sync; use std::from_str::FromStr; use std::iter::count; diff --git a/src/test/bench/std-smallintmap.rs b/src/test/bench/std-smallintmap.rs index 58f667b929ff4..6f9c6abea1b47 100644 --- a/src/test/bench/std-smallintmap.rs +++ b/src/test/bench/std-smallintmap.rs @@ -10,8 +10,8 @@ // Microbenchmark for the smallintmap library -extern mod extra; -extern mod collections; +extern crate extra; +extern crate collections; use collections::SmallIntMap; use std::os; diff --git a/src/test/bench/sudoku.rs b/src/test/bench/sudoku.rs index 371e07bc7d941..a4041ae181644 100644 --- a/src/test/bench/sudoku.rs +++ b/src/test/bench/sudoku.rs @@ -12,7 +12,7 @@ #[feature(managed_boxes)]; -extern mod extra; +extern crate extra; use std::io; use std::io::stdio::StdReader; diff --git a/src/test/bench/task-perf-alloc-unwind.rs b/src/test/bench/task-perf-alloc-unwind.rs index 42b564edbc521..013df3b3675d0 100644 --- a/src/test/bench/task-perf-alloc-unwind.rs +++ b/src/test/bench/task-perf-alloc-unwind.rs @@ -10,8 +10,8 @@ #[feature(managed_boxes)]; -extern mod extra; -extern mod collections; +extern crate extra; +extern crate collections; use collections::list::{List, Cons, Nil}; use extra::time::precise_time_s; diff --git a/src/test/compile-fail/ambig_impl_2_exe.rs b/src/test/compile-fail/ambig_impl_2_exe.rs index ca1e0293f8ee7..a7a0243853018 100644 --- a/src/test/compile-fail/ambig_impl_2_exe.rs +++ b/src/test/compile-fail/ambig_impl_2_exe.rs @@ -10,7 +10,7 @@ // ignore-fast aux-build // aux-build:ambig_impl_2_lib.rs -extern mod ambig_impl_2_lib; +extern crate ambig_impl_2_lib; use ambig_impl_2_lib::me; trait me { fn me(&self) -> uint; diff --git a/src/test/compile-fail/arc-cant-nest-rw-arc-3177.rs b/src/test/compile-fail/arc-cant-nest-rw-arc-3177.rs index 5c55f10ab4f2a..151f4940d5702 100644 --- a/src/test/compile-fail/arc-cant-nest-rw-arc-3177.rs +++ b/src/test/compile-fail/arc-cant-nest-rw-arc-3177.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod sync; +extern crate sync; use sync::RWArc; fn main() { diff --git a/src/test/compile-fail/arc-rw-cond-shouldnt-escape.rs b/src/test/compile-fail/arc-rw-cond-shouldnt-escape.rs index c9cd132788225..71d42d46e7c5f 100644 --- a/src/test/compile-fail/arc-rw-cond-shouldnt-escape.rs +++ b/src/test/compile-fail/arc-rw-cond-shouldnt-escape.rs @@ -9,7 +9,7 @@ // except according to those terms. // error-pattern: lifetime of return value does not outlive the function call -extern mod sync; +extern crate sync; use sync::RWArc; fn main() { let x = ~RWArc::new(1); diff --git a/src/test/compile-fail/arc-rw-read-mode-shouldnt-escape.rs b/src/test/compile-fail/arc-rw-read-mode-shouldnt-escape.rs index 653f37d96d473..1787cd5d0b46c 100644 --- a/src/test/compile-fail/arc-rw-read-mode-shouldnt-escape.rs +++ b/src/test/compile-fail/arc-rw-read-mode-shouldnt-escape.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod sync; +extern crate sync; use sync::RWArc; fn main() { let x = ~RWArc::new(1); diff --git a/src/test/compile-fail/arc-rw-state-shouldnt-escape.rs b/src/test/compile-fail/arc-rw-state-shouldnt-escape.rs index 4bb7653d23e5c..cccca050696a3 100644 --- a/src/test/compile-fail/arc-rw-state-shouldnt-escape.rs +++ b/src/test/compile-fail/arc-rw-state-shouldnt-escape.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod sync; +extern crate sync; use sync::RWArc; fn main() { let x = ~RWArc::new(1); diff --git a/src/test/compile-fail/arc-rw-write-mode-cond-shouldnt-escape.rs b/src/test/compile-fail/arc-rw-write-mode-cond-shouldnt-escape.rs index 1410308107e94..a08cb055020a5 100644 --- a/src/test/compile-fail/arc-rw-write-mode-cond-shouldnt-escape.rs +++ b/src/test/compile-fail/arc-rw-write-mode-cond-shouldnt-escape.rs @@ -9,7 +9,7 @@ // except according to those terms. // error-pattern: lifetime of variable does not enclose its declaration -extern mod sync; +extern crate sync; use sync::RWArc; fn main() { let x = ~RWArc::new(1); diff --git a/src/test/compile-fail/arc-rw-write-mode-shouldnt-escape.rs b/src/test/compile-fail/arc-rw-write-mode-shouldnt-escape.rs index 68226d96a18ef..8f93d672b9016 100644 --- a/src/test/compile-fail/arc-rw-write-mode-shouldnt-escape.rs +++ b/src/test/compile-fail/arc-rw-write-mode-shouldnt-escape.rs @@ -9,7 +9,7 @@ // except according to those terms. // error-pattern: lifetime of variable does not enclose its declaration -extern mod sync; +extern crate sync; use sync::RWArc; fn main() { let x = ~RWArc::new(1); diff --git a/src/test/compile-fail/builtin-superkinds-in-metadata.rs b/src/test/compile-fail/builtin-superkinds-in-metadata.rs index 34dc69d7ecada..bd85141171eb4 100644 --- a/src/test/compile-fail/builtin-superkinds-in-metadata.rs +++ b/src/test/compile-fail/builtin-superkinds-in-metadata.rs @@ -15,7 +15,7 @@ // Test for traits inheriting from the builtin kinds cross-crate. // Mostly tests correctness of metadata. -extern mod trait_superkinds_in_metadata; +extern crate trait_superkinds_in_metadata; use trait_superkinds_in_metadata::{RequiresRequiresFreezeAndSend, RequiresFreeze}; struct X(T); diff --git a/src/test/compile-fail/coherence_inherent_cc.rs b/src/test/compile-fail/coherence_inherent_cc.rs index e2a36ae1361e6..dcecbd5658de3 100644 --- a/src/test/compile-fail/coherence_inherent_cc.rs +++ b/src/test/compile-fail/coherence_inherent_cc.rs @@ -14,7 +14,7 @@ // Tests that methods that implement a trait cannot be invoked // unless the trait is imported. -extern mod coherence_inherent_cc_lib; +extern crate coherence_inherent_cc_lib; mod Import { // Trait is in scope here: diff --git a/src/test/compile-fail/conflicting-implementations-aux.rs b/src/test/compile-fail/conflicting-implementations-aux.rs index 3a1f696193e96..6c7722bbd254d 100644 --- a/src/test/compile-fail/conflicting-implementations-aux.rs +++ b/src/test/compile-fail/conflicting-implementations-aux.rs @@ -12,7 +12,7 @@ // 'conflicting implementations' error message. // aux-build:trait_impl_conflict.rs -extern mod trait_impl_conflict; +extern crate trait_impl_conflict; use trait_impl_conflict::Foo; impl Foo for A { diff --git a/src/test/compile-fail/crateresolve1.rs b/src/test/compile-fail/crateresolve1.rs index c7aa2d3240816..8c3dbda680201 100644 --- a/src/test/compile-fail/crateresolve1.rs +++ b/src/test/compile-fail/crateresolve1.rs @@ -13,7 +13,7 @@ // aux-build:crateresolve1-3.rs // error-pattern:multiple matching crates for `crateresolve1` -extern mod crateresolve1; +extern crate crateresolve1; fn main() { } diff --git a/src/test/compile-fail/crateresolve2.rs b/src/test/compile-fail/crateresolve2.rs index b1565d4b3a150..c5e9d1281526d 100644 --- a/src/test/compile-fail/crateresolve2.rs +++ b/src/test/compile-fail/crateresolve2.rs @@ -13,10 +13,10 @@ // aux-build:crateresolve2-3.rs // error-pattern:using multiple versions of crate `crateresolve2` -extern mod crateresolve2 = "crateresolve2#0.1"; +extern crate crateresolve2 = "crateresolve2#0.1"; mod m { - pub extern mod crateresolve2 = "crateresolve2#0.2"; + pub extern crate crateresolve2 = "crateresolve2#0.2"; } fn main() { diff --git a/src/test/compile-fail/crateresolve5.rs b/src/test/compile-fail/crateresolve5.rs index 127b7575a7e0c..124696630cc08 100644 --- a/src/test/compile-fail/crateresolve5.rs +++ b/src/test/compile-fail/crateresolve5.rs @@ -12,8 +12,8 @@ // aux-build:crateresolve5-1.rs // aux-build:crateresolve5-2.rs -extern mod cr5_1 = "crateresolve5#0.1"; -extern mod cr5_2 = "crateresolve5#0.2"; +extern crate cr5_1 = "crateresolve5#0.1"; +extern crate cr5_2 = "crateresolve5#0.2"; fn main() { diff --git a/src/test/compile-fail/deriving-span-Clone-enum-struct-variant.rs b/src/test/compile-fail/deriving-span-Clone-enum-struct-variant.rs index 983156f9b4ffb..89839c06f3baa 100644 --- a/src/test/compile-fail/deriving-span-Clone-enum-struct-variant.rs +++ b/src/test/compile-fail/deriving-span-Clone-enum-struct-variant.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Clone-enum.rs b/src/test/compile-fail/deriving-span-Clone-enum.rs index e5ceef886e1d3..4c47e77dd8178 100644 --- a/src/test/compile-fail/deriving-span-Clone-enum.rs +++ b/src/test/compile-fail/deriving-span-Clone-enum.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Clone-struct.rs b/src/test/compile-fail/deriving-span-Clone-struct.rs index fd763df311c67..1a2eb3fc6403e 100644 --- a/src/test/compile-fail/deriving-span-Clone-struct.rs +++ b/src/test/compile-fail/deriving-span-Clone-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Clone-tuple-struct.rs b/src/test/compile-fail/deriving-span-Clone-tuple-struct.rs index d444c5e316168..03fb284b50b83 100644 --- a/src/test/compile-fail/deriving-span-Clone-tuple-struct.rs +++ b/src/test/compile-fail/deriving-span-Clone-tuple-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-DeepClone-enum-struct-variant.rs b/src/test/compile-fail/deriving-span-DeepClone-enum-struct-variant.rs index 0dc6266bec41b..7cee7b8ee0d0a 100644 --- a/src/test/compile-fail/deriving-span-DeepClone-enum-struct-variant.rs +++ b/src/test/compile-fail/deriving-span-DeepClone-enum-struct-variant.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; #[deriving(Clone)] struct Error; diff --git a/src/test/compile-fail/deriving-span-DeepClone-enum.rs b/src/test/compile-fail/deriving-span-DeepClone-enum.rs index 5b210d0ff7964..c18ebe1758d3e 100644 --- a/src/test/compile-fail/deriving-span-DeepClone-enum.rs +++ b/src/test/compile-fail/deriving-span-DeepClone-enum.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; #[deriving(Clone)] struct Error; diff --git a/src/test/compile-fail/deriving-span-DeepClone-struct.rs b/src/test/compile-fail/deriving-span-DeepClone-struct.rs index f063ed58dce5b..7d33cd1a28df1 100644 --- a/src/test/compile-fail/deriving-span-DeepClone-struct.rs +++ b/src/test/compile-fail/deriving-span-DeepClone-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; #[deriving(Clone)] struct Error; diff --git a/src/test/compile-fail/deriving-span-DeepClone-tuple-struct.rs b/src/test/compile-fail/deriving-span-DeepClone-tuple-struct.rs index 1b053897c0e01..42dd608f61781 100644 --- a/src/test/compile-fail/deriving-span-DeepClone-tuple-struct.rs +++ b/src/test/compile-fail/deriving-span-DeepClone-tuple-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; #[deriving(Clone)] struct Error; diff --git a/src/test/compile-fail/deriving-span-Default-struct.rs b/src/test/compile-fail/deriving-span-Default-struct.rs index 7c2edd8cb7bff..21da9fef3982f 100644 --- a/src/test/compile-fail/deriving-span-Default-struct.rs +++ b/src/test/compile-fail/deriving-span-Default-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Default-tuple-struct.rs b/src/test/compile-fail/deriving-span-Default-tuple-struct.rs index e0269a6aad3b2..2cfc7e2a259a3 100644 --- a/src/test/compile-fail/deriving-span-Default-tuple-struct.rs +++ b/src/test/compile-fail/deriving-span-Default-tuple-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Eq-enum-struct-variant.rs b/src/test/compile-fail/deriving-span-Eq-enum-struct-variant.rs index abedb3e660f18..ce3d84a2e9b41 100644 --- a/src/test/compile-fail/deriving-span-Eq-enum-struct-variant.rs +++ b/src/test/compile-fail/deriving-span-Eq-enum-struct-variant.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Eq-enum.rs b/src/test/compile-fail/deriving-span-Eq-enum.rs index 3486d96205b4d..c59a81fd147c6 100644 --- a/src/test/compile-fail/deriving-span-Eq-enum.rs +++ b/src/test/compile-fail/deriving-span-Eq-enum.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Eq-struct.rs b/src/test/compile-fail/deriving-span-Eq-struct.rs index 32d2e78eabcef..b797a0d7790a3 100644 --- a/src/test/compile-fail/deriving-span-Eq-struct.rs +++ b/src/test/compile-fail/deriving-span-Eq-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Eq-tuple-struct.rs b/src/test/compile-fail/deriving-span-Eq-tuple-struct.rs index acc46a1002af1..fb4d850ed11e2 100644 --- a/src/test/compile-fail/deriving-span-Eq-tuple-struct.rs +++ b/src/test/compile-fail/deriving-span-Eq-tuple-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Ord-enum-struct-variant.rs b/src/test/compile-fail/deriving-span-Ord-enum-struct-variant.rs index 933da411db8b7..e3e442e70cf99 100644 --- a/src/test/compile-fail/deriving-span-Ord-enum-struct-variant.rs +++ b/src/test/compile-fail/deriving-span-Ord-enum-struct-variant.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Ord-enum.rs b/src/test/compile-fail/deriving-span-Ord-enum.rs index c310965cfa1b9..41e6c2c9e8dad 100644 --- a/src/test/compile-fail/deriving-span-Ord-enum.rs +++ b/src/test/compile-fail/deriving-span-Ord-enum.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Ord-struct.rs b/src/test/compile-fail/deriving-span-Ord-struct.rs index 327ac73ff2d98..2caf68a26fcc2 100644 --- a/src/test/compile-fail/deriving-span-Ord-struct.rs +++ b/src/test/compile-fail/deriving-span-Ord-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Ord-tuple-struct.rs b/src/test/compile-fail/deriving-span-Ord-tuple-struct.rs index 2a482f872c59a..c783befa3919c 100644 --- a/src/test/compile-fail/deriving-span-Ord-tuple-struct.rs +++ b/src/test/compile-fail/deriving-span-Ord-tuple-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Rand-enum-struct-variant.rs b/src/test/compile-fail/deriving-span-Rand-enum-struct-variant.rs index ae0732e4db634..615112c129e22 100644 --- a/src/test/compile-fail/deriving-span-Rand-enum-struct-variant.rs +++ b/src/test/compile-fail/deriving-span-Rand-enum-struct-variant.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Rand-enum.rs b/src/test/compile-fail/deriving-span-Rand-enum.rs index ef29ce082923d..a1943941e4171 100644 --- a/src/test/compile-fail/deriving-span-Rand-enum.rs +++ b/src/test/compile-fail/deriving-span-Rand-enum.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Rand-struct.rs b/src/test/compile-fail/deriving-span-Rand-struct.rs index 2ce4d49e72153..00d9c1de5c55f 100644 --- a/src/test/compile-fail/deriving-span-Rand-struct.rs +++ b/src/test/compile-fail/deriving-span-Rand-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Rand-tuple-struct.rs b/src/test/compile-fail/deriving-span-Rand-tuple-struct.rs index 3f6738fd306d4..c61a7c76bfb16 100644 --- a/src/test/compile-fail/deriving-span-Rand-tuple-struct.rs +++ b/src/test/compile-fail/deriving-span-Rand-tuple-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Show-enum-struct-variant.rs b/src/test/compile-fail/deriving-span-Show-enum-struct-variant.rs index 582c95b746b7a..e22b51d19e56e 100644 --- a/src/test/compile-fail/deriving-span-Show-enum-struct-variant.rs +++ b/src/test/compile-fail/deriving-span-Show-enum-struct-variant.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Show-enum.rs b/src/test/compile-fail/deriving-span-Show-enum.rs index 92efe01fa3863..fffbd49a2bb38 100644 --- a/src/test/compile-fail/deriving-span-Show-enum.rs +++ b/src/test/compile-fail/deriving-span-Show-enum.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Show-struct.rs b/src/test/compile-fail/deriving-span-Show-struct.rs index 7eff82f9d13ff..45afd4454e86b 100644 --- a/src/test/compile-fail/deriving-span-Show-struct.rs +++ b/src/test/compile-fail/deriving-span-Show-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Show-tuple-struct.rs b/src/test/compile-fail/deriving-span-Show-tuple-struct.rs index 600a0400350db..1a199974eba0f 100644 --- a/src/test/compile-fail/deriving-span-Show-tuple-struct.rs +++ b/src/test/compile-fail/deriving-span-Show-tuple-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-TotalEq-enum-struct-variant.rs b/src/test/compile-fail/deriving-span-TotalEq-enum-struct-variant.rs index 8e55609a515d8..f054e9e7e77f6 100644 --- a/src/test/compile-fail/deriving-span-TotalEq-enum-struct-variant.rs +++ b/src/test/compile-fail/deriving-span-TotalEq-enum-struct-variant.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-TotalEq-enum.rs b/src/test/compile-fail/deriving-span-TotalEq-enum.rs index 968f0420687c5..38b8d55bcd83a 100644 --- a/src/test/compile-fail/deriving-span-TotalEq-enum.rs +++ b/src/test/compile-fail/deriving-span-TotalEq-enum.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-TotalEq-struct.rs b/src/test/compile-fail/deriving-span-TotalEq-struct.rs index 8c53d1167f12f..66e5ef57a00b5 100644 --- a/src/test/compile-fail/deriving-span-TotalEq-struct.rs +++ b/src/test/compile-fail/deriving-span-TotalEq-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-TotalEq-tuple-struct.rs b/src/test/compile-fail/deriving-span-TotalEq-tuple-struct.rs index 16d49954dce7a..dd0be2dc04a65 100644 --- a/src/test/compile-fail/deriving-span-TotalEq-tuple-struct.rs +++ b/src/test/compile-fail/deriving-span-TotalEq-tuple-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-TotalOrd-enum-struct-variant.rs b/src/test/compile-fail/deriving-span-TotalOrd-enum-struct-variant.rs index fe598906c0288..76bcd33256240 100644 --- a/src/test/compile-fail/deriving-span-TotalOrd-enum-struct-variant.rs +++ b/src/test/compile-fail/deriving-span-TotalOrd-enum-struct-variant.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; #[deriving(TotalEq)] struct Error; diff --git a/src/test/compile-fail/deriving-span-TotalOrd-enum.rs b/src/test/compile-fail/deriving-span-TotalOrd-enum.rs index 6bccd22c45f8e..303e35108feea 100644 --- a/src/test/compile-fail/deriving-span-TotalOrd-enum.rs +++ b/src/test/compile-fail/deriving-span-TotalOrd-enum.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; #[deriving(TotalEq)] struct Error; diff --git a/src/test/compile-fail/deriving-span-TotalOrd-struct.rs b/src/test/compile-fail/deriving-span-TotalOrd-struct.rs index 4ff48824a7bac..bbcc3ae7e047a 100644 --- a/src/test/compile-fail/deriving-span-TotalOrd-struct.rs +++ b/src/test/compile-fail/deriving-span-TotalOrd-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; #[deriving(TotalEq)] struct Error; diff --git a/src/test/compile-fail/deriving-span-TotalOrd-tuple-struct.rs b/src/test/compile-fail/deriving-span-TotalOrd-tuple-struct.rs index 08e2c9bcd7d9a..4e8697749e76e 100644 --- a/src/test/compile-fail/deriving-span-TotalOrd-tuple-struct.rs +++ b/src/test/compile-fail/deriving-span-TotalOrd-tuple-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; #[deriving(TotalEq)] struct Error; diff --git a/src/test/compile-fail/deriving-span-Zero-struct.rs b/src/test/compile-fail/deriving-span-Zero-struct.rs index 2892938926b49..7256b1179dbf4 100644 --- a/src/test/compile-fail/deriving-span-Zero-struct.rs +++ b/src/test/compile-fail/deriving-span-Zero-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/deriving-span-Zero-tuple-struct.rs b/src/test/compile-fail/deriving-span-Zero-tuple-struct.rs index 43d84a593edae..d483a86fddbb8 100644 --- a/src/test/compile-fail/deriving-span-Zero-tuple-struct.rs +++ b/src/test/compile-fail/deriving-span-Zero-tuple-struct.rs @@ -11,7 +11,7 @@ // This file was auto-generated using 'src/etc/generate-keyword-span-tests.py' #[feature(struct_variant)]; -extern mod extra; +extern crate extra; struct Error; diff --git a/src/test/compile-fail/functional-struct-update-noncopyable.rs b/src/test/compile-fail/functional-struct-update-noncopyable.rs index 5b634818d4436..244ae47a277e7 100644 --- a/src/test/compile-fail/functional-struct-update-noncopyable.rs +++ b/src/test/compile-fail/functional-struct-update-noncopyable.rs @@ -11,7 +11,7 @@ // issue 7327 // ignore-fast #7103 -extern mod sync; +extern crate sync; use sync::Arc; struct A { y: Arc, x: Arc } diff --git a/src/test/compile-fail/future_not_copyable.rs b/src/test/compile-fail/future_not_copyable.rs index 69a90275ec78b..e44efc140a5e3 100644 --- a/src/test/compile-fail/future_not_copyable.rs +++ b/src/test/compile-fail/future_not_copyable.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod sync; +extern crate sync; use sync::Future; diff --git a/src/test/compile-fail/gated-non-ascii-idents.rs b/src/test/compile-fail/gated-non-ascii-idents.rs index 96814e11049e0..f37a6aa354a5f 100644 --- a/src/test/compile-fail/gated-non-ascii-idents.rs +++ b/src/test/compile-fail/gated-non-ascii-idents.rs @@ -12,7 +12,7 @@ #[feature(struct_variant)]; -extern mod bäz; //~ ERROR non-ascii idents +extern crate bäz; //~ ERROR non-ascii idents use föö::bar; //~ ERROR non-ascii idents diff --git a/src/test/compile-fail/gated-phase.rs b/src/test/compile-fail/gated-phase.rs index 3a801e1351ac9..416a7691ceb5f 100644 --- a/src/test/compile-fail/gated-phase.rs +++ b/src/test/compile-fail/gated-phase.rs @@ -12,6 +12,6 @@ #[phase(syntax)] //~^ ERROR compile time crate loading is experimental and possibly buggy -extern mod macro_crate_test; +extern crate macro_crate_test; fn main() {} diff --git a/src/test/compile-fail/gated-simd.rs b/src/test/compile-fail/gated-simd.rs index a000b91dfdea3..59c44bff3c79d 100644 --- a/src/test/compile-fail/gated-simd.rs +++ b/src/test/compile-fail/gated-simd.rs @@ -11,4 +11,4 @@ #[simd] pub struct i64x2(i64, i64); //~ ERROR: SIMD types are experimental -fn main() {} \ No newline at end of file +fn main() {} diff --git a/src/test/compile-fail/issue-11593.rs b/src/test/compile-fail/issue-11593.rs index 9ca91f067ba03..ecc584d81b0e1 100644 --- a/src/test/compile-fail/issue-11593.rs +++ b/src/test/compile-fail/issue-11593.rs @@ -10,7 +10,7 @@ // aux-build:private_trait_xc.rs -extern mod private_trait_xc; +extern crate private_trait_xc; struct Bar; diff --git a/src/test/compile-fail/issue-3021-b.rs b/src/test/compile-fail/issue-3021-b.rs index 641403fb85a14..038b2b0d87624 100644 --- a/src/test/compile-fail/issue-3021-b.rs +++ b/src/test/compile-fail/issue-3021-b.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; fn siphash(k0 : u64) { diff --git a/src/test/compile-fail/issue-3021-c.rs b/src/test/compile-fail/issue-3021-c.rs index a0b78a4bc79b1..392cc2f3c9006 100644 --- a/src/test/compile-fail/issue-3021-c.rs +++ b/src/test/compile-fail/issue-3021-c.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; fn siphash() { diff --git a/src/test/compile-fail/issue-3021-d.rs b/src/test/compile-fail/issue-3021-d.rs index c5ee9e8bb90e1..95c0eb711e8f7 100644 --- a/src/test/compile-fail/issue-3021-d.rs +++ b/src/test/compile-fail/issue-3021-d.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; trait siphash { fn result(&self) -> u64; diff --git a/src/test/compile-fail/issue-3021.rs b/src/test/compile-fail/issue-3021.rs index 56ade814db020..7bb1faf514a04 100644 --- a/src/test/compile-fail/issue-3021.rs +++ b/src/test/compile-fail/issue-3021.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; trait SipHash { fn reset(&self); diff --git a/src/test/compile-fail/issue-3907.rs b/src/test/compile-fail/issue-3907.rs index df18a5ad2d321..5d292531b49ff 100644 --- a/src/test/compile-fail/issue-3907.rs +++ b/src/test/compile-fail/issue-3907.rs @@ -9,7 +9,7 @@ // except according to those terms. // aux-build:issue_3907.rs -extern mod issue_3907; +extern crate issue_3907; type Foo = issue_3907::Foo; //~ ERROR: reference to trait diff --git a/src/test/compile-fail/issue-5844.rs b/src/test/compile-fail/issue-5844.rs index 9d4c3cfa6784e..6c85a97f7f57f 100644 --- a/src/test/compile-fail/issue-5844.rs +++ b/src/test/compile-fail/issue-5844.rs @@ -10,7 +10,7 @@ //aux-build:issue_5844_aux.rs -extern mod issue_5844_aux; +extern crate issue_5844_aux; fn main () { issue_5844_aux::rand(); //~ ERROR: requires unsafe diff --git a/src/test/compile-fail/issue-9957.rs b/src/test/compile-fail/issue-9957.rs index b8292d617525e..da90c4ee7531e 100644 --- a/src/test/compile-fail/issue-9957.rs +++ b/src/test/compile-fail/issue-9957.rs @@ -8,9 +8,9 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -pub extern mod std; //~ ERROR: `pub` visibility is not allowed -priv extern mod std; //~ ERROR: unnecessary visibility qualifier -extern mod std; +pub extern crate std; //~ ERROR: `pub` visibility is not allowed +priv extern crate std; //~ ERROR: unnecessary visibility qualifier +extern crate std; pub use std::bool; priv use std::bool; //~ ERROR: unnecessary visibility qualifier diff --git a/src/test/compile-fail/lint-stability.rs b/src/test/compile-fail/lint-stability.rs index 84a1707811699..f45f654229f54 100644 --- a/src/test/compile-fail/lint-stability.rs +++ b/src/test/compile-fail/lint-stability.rs @@ -18,7 +18,7 @@ #[allow(dead_code)]; mod cross_crate { - extern mod lint_stability; + extern crate lint_stability; use self::lint_stability::*; fn test() { diff --git a/src/test/compile-fail/log-syntax-gate.rs b/src/test/compile-fail/log-syntax-gate.rs index b74c1d61eb814..63c66e53c5ee8 100644 --- a/src/test/compile-fail/log-syntax-gate.rs +++ b/src/test/compile-fail/log-syntax-gate.rs @@ -10,4 +10,4 @@ fn main() { log_syntax!() //~ ERROR `log_syntax!` is not stable enough -} \ No newline at end of file +} diff --git a/src/test/compile-fail/macro-crate-unexported-macro.rs b/src/test/compile-fail/macro-crate-unexported-macro.rs index e111393d9a754..aaf89807ced31 100644 --- a/src/test/compile-fail/macro-crate-unexported-macro.rs +++ b/src/test/compile-fail/macro-crate-unexported-macro.rs @@ -15,7 +15,7 @@ #[feature(phase)]; #[phase(syntax)] -extern mod macro_crate_test; +extern crate macro_crate_test; fn main() { assert_eq!(3, unexported_macro!()); //~ ERROR macro undefined: 'unexported_macro' diff --git a/src/test/compile-fail/macro-crate-unknown-crate.rs b/src/test/compile-fail/macro-crate-unknown-crate.rs index 83538fcf454e8..3301eb145ce27 100644 --- a/src/test/compile-fail/macro-crate-unknown-crate.rs +++ b/src/test/compile-fail/macro-crate-unknown-crate.rs @@ -11,6 +11,6 @@ #[feature(phase)]; #[phase(syntax)] -extern mod doesnt_exist; //~ ERROR can't find crate +extern crate doesnt_exist; //~ ERROR can't find crate fn main() {} diff --git a/src/test/compile-fail/moves-based-on-type-cyclic-types-issue-4821.rs b/src/test/compile-fail/moves-based-on-type-cyclic-types-issue-4821.rs index 7c01ddb6c9331..97a2b00ba424c 100644 --- a/src/test/compile-fail/moves-based-on-type-cyclic-types-issue-4821.rs +++ b/src/test/compile-fail/moves-based-on-type-cyclic-types-issue-4821.rs @@ -12,7 +12,7 @@ // temporary kinds wound up being stored in a cache and used later. // See middle::ty::type_contents() for more information. -extern mod extra; +extern crate extra; struct List { key: int, next: Option<~List> } diff --git a/src/test/compile-fail/mutex-arc-nested.rs b/src/test/compile-fail/mutex-arc-nested.rs index cdfdd29410e76..34c56f98404d3 100644 --- a/src/test/compile-fail/mutex-arc-nested.rs +++ b/src/test/compile-fail/mutex-arc-nested.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod sync; +extern crate sync; use std::task; use sync::MutexArc; diff --git a/src/test/compile-fail/no-capture-arc.rs b/src/test/compile-fail/no-capture-arc.rs index cc529abd6f94f..8df156d8332fe 100644 --- a/src/test/compile-fail/no-capture-arc.rs +++ b/src/test/compile-fail/no-capture-arc.rs @@ -10,7 +10,7 @@ // error-pattern: use of moved value -extern mod sync; +extern crate sync; use sync::Arc; use std::task; diff --git a/src/test/compile-fail/no-reuse-move-arc.rs b/src/test/compile-fail/no-reuse-move-arc.rs index 204a0e1cdd4a0..b387d3a1719e9 100644 --- a/src/test/compile-fail/no-reuse-move-arc.rs +++ b/src/test/compile-fail/no-reuse-move-arc.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod sync; +extern crate sync; use sync::Arc; use std::task; diff --git a/src/test/compile-fail/noexporttypeexe.rs b/src/test/compile-fail/noexporttypeexe.rs index 3add0134d002a..7091995fa7729 100644 --- a/src/test/compile-fail/noexporttypeexe.rs +++ b/src/test/compile-fail/noexporttypeexe.rs @@ -10,7 +10,7 @@ // aux-build:noexporttypelib.rs -extern mod noexporttypelib; +extern crate noexporttypelib; fn main() { // Here, the type returned by foo() is not exported. diff --git a/src/test/compile-fail/once-cant-call-twice-on-heap.rs b/src/test/compile-fail/once-cant-call-twice-on-heap.rs index a7e4f8de43704..675dcf95595a8 100644 --- a/src/test/compile-fail/once-cant-call-twice-on-heap.rs +++ b/src/test/compile-fail/once-cant-call-twice-on-heap.rs @@ -12,7 +12,7 @@ // This program would segfault if it were legal. #[feature(once_fns)]; -extern mod sync; +extern crate sync; use sync::Arc; fn foo(blk: proc()) { diff --git a/src/test/compile-fail/once-cant-call-twice-on-stack.rs b/src/test/compile-fail/once-cant-call-twice-on-stack.rs index 8b168dd67870e..48dd484c1c26b 100644 --- a/src/test/compile-fail/once-cant-call-twice-on-stack.rs +++ b/src/test/compile-fail/once-cant-call-twice-on-stack.rs @@ -12,7 +12,7 @@ // This program would segfault if it were legal. #[feature(once_fns)]; -extern mod sync; +extern crate sync; use sync::Arc; fn foo(blk: once ||) { diff --git a/src/test/compile-fail/once-cant-move-out-of-non-once-on-stack.rs b/src/test/compile-fail/once-cant-move-out-of-non-once-on-stack.rs index 4fa6b6af7949e..804ea46b4266f 100644 --- a/src/test/compile-fail/once-cant-move-out-of-non-once-on-stack.rs +++ b/src/test/compile-fail/once-cant-move-out-of-non-once-on-stack.rs @@ -11,7 +11,7 @@ // Testing guarantees provided by once functions. // This program would segfault if it were legal. -extern mod sync; +extern crate sync; use sync::Arc; fn foo(blk: ||) { diff --git a/src/test/compile-fail/pattern-tyvar-2.rs b/src/test/compile-fail/pattern-tyvar-2.rs index a26733ebcee66..e58c4b1468588 100644 --- a/src/test/compile-fail/pattern-tyvar-2.rs +++ b/src/test/compile-fail/pattern-tyvar-2.rs @@ -9,7 +9,7 @@ // except according to those terms. -extern mod extra; +extern crate extra; enum bar { t1((), Option<~[int]>), t2, } diff --git a/src/test/compile-fail/pattern-tyvar.rs b/src/test/compile-fail/pattern-tyvar.rs index b3e907f913f0c..b687a225754e0 100644 --- a/src/test/compile-fail/pattern-tyvar.rs +++ b/src/test/compile-fail/pattern-tyvar.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; // error-pattern: mismatched types diff --git a/src/test/compile-fail/phase-syntax-doesnt-resolve.rs b/src/test/compile-fail/phase-syntax-doesnt-resolve.rs index 8561006fbe966..8efa910f7c6aa 100644 --- a/src/test/compile-fail/phase-syntax-doesnt-resolve.rs +++ b/src/test/compile-fail/phase-syntax-doesnt-resolve.rs @@ -15,7 +15,7 @@ #[feature(phase)]; #[phase(syntax)] -extern mod macro_crate_test; +extern crate macro_crate_test; fn main() { macro_crate_test::foo(); diff --git a/src/test/compile-fail/private-method-cross-crate.rs b/src/test/compile-fail/private-method-cross-crate.rs index 4e5645c00c7c4..2e79c0f46adb5 100644 --- a/src/test/compile-fail/private-method-cross-crate.rs +++ b/src/test/compile-fail/private-method-cross-crate.rs @@ -10,7 +10,7 @@ // ignore-fast // aux-build:cci_class_5.rs -extern mod cci_class_5; +extern crate cci_class_5; use cci_class_5::kitties::cat; fn main() { diff --git a/src/test/compile-fail/private-struct-field-cross-crate.rs b/src/test/compile-fail/private-struct-field-cross-crate.rs index 0b46e8d0a8206..0993ac9a64ad3 100644 --- a/src/test/compile-fail/private-struct-field-cross-crate.rs +++ b/src/test/compile-fail/private-struct-field-cross-crate.rs @@ -9,7 +9,7 @@ // except according to those terms. // aux-build:cci_class.rs -extern mod cci_class; +extern crate cci_class; use cci_class::kitties::cat; fn main() { diff --git a/src/test/compile-fail/private-variant-xc.rs b/src/test/compile-fail/private-variant-xc.rs index d6c614b707045..5a252eb297527 100644 --- a/src/test/compile-fail/private-variant-xc.rs +++ b/src/test/compile-fail/private-variant-xc.rs @@ -11,7 +11,7 @@ // ignore-test // aux-build:private_variant_xc.rs -extern mod private_variant_xc; +extern crate private_variant_xc; pub fn main() { let _ = private_variant_xc::Bar; diff --git a/src/test/compile-fail/private_variant_2.rs b/src/test/compile-fail/private_variant_2.rs index 86f1a97b1d64c..4afbe7ed48b1c 100644 --- a/src/test/compile-fail/private_variant_2.rs +++ b/src/test/compile-fail/private_variant_2.rs @@ -11,7 +11,7 @@ // ignore-test // aux-build:private_variant_1.rs -extern mod private_variant_1; +extern crate private_variant_1; fn main() { let _x = private_variant_1::super_sekrit::baz; //~ ERROR baz is private diff --git a/src/test/compile-fail/qquote-1.rs b/src/test/compile-fail/qquote-1.rs index cc3513b8fe623..d45759e38d99e 100644 --- a/src/test/compile-fail/qquote-1.rs +++ b/src/test/compile-fail/qquote-1.rs @@ -12,8 +12,8 @@ #[feature(quote)]; -extern mod extra; -extern mod syntax; +extern crate extra; +extern crate syntax; use io::*; diff --git a/src/test/compile-fail/qquote-2.rs b/src/test/compile-fail/qquote-2.rs index 165a1e2663cbd..b5c2dee61c736 100644 --- a/src/test/compile-fail/qquote-2.rs +++ b/src/test/compile-fail/qquote-2.rs @@ -12,8 +12,8 @@ #[feature(quote)]; -extern mod extra; -extern mod syntax; +extern crate extra; +extern crate syntax; use extra::io::*; diff --git a/src/test/compile-fail/regions-glb-free-free.rs b/src/test/compile-fail/regions-glb-free-free.rs index 1aafd9057c266..8453ace2b51d9 100644 --- a/src/test/compile-fail/regions-glb-free-free.rs +++ b/src/test/compile-fail/regions-glb-free-free.rs @@ -9,7 +9,7 @@ // except according to those terms. mod argparse { - extern mod extra; + extern crate extra; pub struct Flag<'a> { name: &'a str, diff --git a/src/test/compile-fail/seq-args.rs b/src/test/compile-fail/seq-args.rs index a6ab41a3d6b74..f543d442a2391 100644 --- a/src/test/compile-fail/seq-args.rs +++ b/src/test/compile-fail/seq-args.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; fn main() { trait seq { } diff --git a/src/test/compile-fail/spawn-non-nil-fn.rs b/src/test/compile-fail/spawn-non-nil-fn.rs index 8db2c686f30ac..e82c49d977f67 100644 --- a/src/test/compile-fail/spawn-non-nil-fn.rs +++ b/src/test/compile-fail/spawn-non-nil-fn.rs @@ -10,7 +10,7 @@ // error-pattern: mismatched types -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/compile-fail/static-priv-by-default.rs b/src/test/compile-fail/static-priv-by-default.rs index 24a2b561a8b0b..98b37242c03a6 100644 --- a/src/test/compile-fail/static-priv-by-default.rs +++ b/src/test/compile-fail/static-priv-by-default.rs @@ -10,7 +10,7 @@ // aux-build:static_priv_by_default.rs -extern mod static_priv_by_default; +extern crate static_priv_by_default; mod child { pub mod childs_child { diff --git a/src/test/compile-fail/static-priv-by-default2.rs b/src/test/compile-fail/static-priv-by-default2.rs index 423d182dd6920..2141099c7aa0e 100644 --- a/src/test/compile-fail/static-priv-by-default2.rs +++ b/src/test/compile-fail/static-priv-by-default2.rs @@ -10,7 +10,7 @@ // aux-build:static_priv_by_default.rs -extern mod static_priv_by_default; +extern crate static_priv_by_default; mod child { pub mod childs_child { diff --git a/src/test/compile-fail/struct-field-privacy.rs b/src/test/compile-fail/struct-field-privacy.rs index f31690047854f..d298d331a3f87 100644 --- a/src/test/compile-fail/struct-field-privacy.rs +++ b/src/test/compile-fail/struct-field-privacy.rs @@ -10,7 +10,7 @@ // aux-build:struct-field-privacy.rs -extern mod xc = "struct-field-privacy"; +extern crate xc = "struct-field-privacy"; struct A { a: int, diff --git a/src/test/compile-fail/sync-cond-shouldnt-escape.rs b/src/test/compile-fail/sync-cond-shouldnt-escape.rs index 06b8ad6259b6b..4ba1c5c7cfeec 100644 --- a/src/test/compile-fail/sync-cond-shouldnt-escape.rs +++ b/src/test/compile-fail/sync-cond-shouldnt-escape.rs @@ -9,7 +9,7 @@ // except according to those terms. // error-pattern: lifetime of variable does not enclose its declaration -extern mod sync; +extern crate sync; use sync::Mutex; fn main() { diff --git a/src/test/compile-fail/sync-rwlock-cond-shouldnt-escape.rs b/src/test/compile-fail/sync-rwlock-cond-shouldnt-escape.rs index 52466c122dd7f..697858f40da60 100644 --- a/src/test/compile-fail/sync-rwlock-cond-shouldnt-escape.rs +++ b/src/test/compile-fail/sync-rwlock-cond-shouldnt-escape.rs @@ -9,7 +9,7 @@ // except according to those terms. // error-pattern: lifetime of method receiver does not outlive the method call -extern mod sync; +extern crate sync; use sync::RWLock; fn main() { let x = ~RWLock::new(); diff --git a/src/test/compile-fail/sync-rwlock-read-mode-shouldnt-escape.rs b/src/test/compile-fail/sync-rwlock-read-mode-shouldnt-escape.rs index cb6c11537c609..30ed0912f6a8a 100644 --- a/src/test/compile-fail/sync-rwlock-read-mode-shouldnt-escape.rs +++ b/src/test/compile-fail/sync-rwlock-read-mode-shouldnt-escape.rs @@ -9,7 +9,7 @@ // except according to those terms. // error-pattern: cannot infer -extern mod sync; +extern crate sync; use sync::RWLock; fn main() { let x = ~RWLock::new(); diff --git a/src/test/compile-fail/sync-rwlock-write-mode-cond-shouldnt-escape.rs b/src/test/compile-fail/sync-rwlock-write-mode-cond-shouldnt-escape.rs index 71a9dd100c395..09b4e34ea8c13 100644 --- a/src/test/compile-fail/sync-rwlock-write-mode-cond-shouldnt-escape.rs +++ b/src/test/compile-fail/sync-rwlock-write-mode-cond-shouldnt-escape.rs @@ -9,7 +9,7 @@ // except according to those terms. // error-pattern: lifetime of variable does not enclose its declaration -extern mod sync; +extern crate sync; use sync::RWLock; fn main() { let x = ~RWLock::new(); diff --git a/src/test/compile-fail/sync-rwlock-write-mode-shouldnt-escape.rs b/src/test/compile-fail/sync-rwlock-write-mode-shouldnt-escape.rs index 53966bf48a493..0fca360d0ce3d 100644 --- a/src/test/compile-fail/sync-rwlock-write-mode-shouldnt-escape.rs +++ b/src/test/compile-fail/sync-rwlock-write-mode-shouldnt-escape.rs @@ -9,7 +9,7 @@ // except according to those terms. // error-pattern: lifetime of variable does not enclose its declaration -extern mod sync; +extern crate sync; use sync::RWLock; fn main() { let x = ~RWLock::new(); diff --git a/src/test/compile-fail/syntax-extension-fourcc-bad-len.rs b/src/test/compile-fail/syntax-extension-fourcc-bad-len.rs index 61594e642bf04..920726a487013 100644 --- a/src/test/compile-fail/syntax-extension-fourcc-bad-len.rs +++ b/src/test/compile-fail/syntax-extension-fourcc-bad-len.rs @@ -15,7 +15,7 @@ #[feature(phase)]; #[phase(syntax)] -extern mod fourcc; +extern crate fourcc; fn main() { let val = fourcc!("foo"); //~ ERROR string literal with len != 4 in fourcc! diff --git a/src/test/compile-fail/syntax-extension-fourcc-invalid-endian.rs b/src/test/compile-fail/syntax-extension-fourcc-invalid-endian.rs index bfc755eda33be..08ee57a2d94ea 100644 --- a/src/test/compile-fail/syntax-extension-fourcc-invalid-endian.rs +++ b/src/test/compile-fail/syntax-extension-fourcc-invalid-endian.rs @@ -15,7 +15,7 @@ #[feature(phase)]; #[phase(syntax)] -extern mod fourcc; +extern crate fourcc; fn main() { let val = fourcc!("foo ", bork); //~ ERROR invalid endian directive in fourcc! diff --git a/src/test/compile-fail/syntax-extension-fourcc-non-ascii-str.rs b/src/test/compile-fail/syntax-extension-fourcc-non-ascii-str.rs index 7b090e3e94705..af49d9988d890 100644 --- a/src/test/compile-fail/syntax-extension-fourcc-non-ascii-str.rs +++ b/src/test/compile-fail/syntax-extension-fourcc-non-ascii-str.rs @@ -15,7 +15,7 @@ #[feature(phase)]; #[phase(syntax)] -extern mod fourcc; +extern crate fourcc; fn main() { let v = fourcc!("fooλ"); //~ ERROR fourcc! literal character out of range 0-255 diff --git a/src/test/compile-fail/syntax-extension-fourcc-non-literal.rs b/src/test/compile-fail/syntax-extension-fourcc-non-literal.rs index 5f6446c683c78..b4195ed9bc88b 100644 --- a/src/test/compile-fail/syntax-extension-fourcc-non-literal.rs +++ b/src/test/compile-fail/syntax-extension-fourcc-non-literal.rs @@ -15,7 +15,7 @@ #[feature(phase)]; #[phase(syntax)] -extern mod fourcc; +extern crate fourcc; fn main() { let val = fourcc!(foo); //~ ERROR non-literal in fourcc! diff --git a/src/test/compile-fail/syntax-extension-fourcc-unsupported-literal.rs b/src/test/compile-fail/syntax-extension-fourcc-unsupported-literal.rs index 48c6d218df498..1997b7ad8e762 100644 --- a/src/test/compile-fail/syntax-extension-fourcc-unsupported-literal.rs +++ b/src/test/compile-fail/syntax-extension-fourcc-unsupported-literal.rs @@ -15,7 +15,7 @@ #[feature(phase)]; #[phase(syntax)] -extern mod fourcc; +extern crate fourcc; fn main() { let val = fourcc!(45f32); //~ ERROR unsupported literal in fourcc! diff --git a/src/test/compile-fail/unresolved-extern-mod-suggestion.rs b/src/test/compile-fail/unresolved-extern-mod-suggestion.rs index f2b1203511cb6..a39ffa64dfd76 100644 --- a/src/test/compile-fail/unresolved-extern-mod-suggestion.rs +++ b/src/test/compile-fail/unresolved-extern-mod-suggestion.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use extra; //~ ERROR unresolved import (maybe you meant `extra::*`?) fn main() {} diff --git a/src/test/compile-fail/unresolved-import.rs b/src/test/compile-fail/unresolved-import.rs index fc69c34c1183b..cb009163697f7 100644 --- a/src/test/compile-fail/unresolved-import.rs +++ b/src/test/compile-fail/unresolved-import.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -use foo::bar; //~ ERROR unresolved import. maybe a missing `extern mod foo`? +use foo::bar; //~ ERROR unresolved import. maybe a missing `extern crate foo`? //~^ ERROR failed to resolve import `foo::bar` use x = bar::baz; //~ ERROR unresolved import: there is no `baz` in `bar` //~^ ERROR failed to resolve import `bar::baz` diff --git a/src/test/compile-fail/use-from-trait-xc.rs b/src/test/compile-fail/use-from-trait-xc.rs index a4db5457750cd..d45387ed1a25b 100644 --- a/src/test/compile-fail/use-from-trait-xc.rs +++ b/src/test/compile-fail/use-from-trait-xc.rs @@ -10,7 +10,7 @@ // aux-build:use_from_trait_xc.rs -extern mod use_from_trait_xc; +extern crate use_from_trait_xc; use use_from_trait_xc::Trait::foo; //~ ERROR cannot import from a trait or type implementation //~^ ERROR failed to resolve import diff --git a/src/test/compile-fail/use-meta-mismatch.rs b/src/test/compile-fail/use-meta-mismatch.rs index dc8250d4134fe..0d84a59fc9ec3 100644 --- a/src/test/compile-fail/use-meta-mismatch.rs +++ b/src/test/compile-fail/use-meta-mismatch.rs @@ -10,6 +10,6 @@ // error-pattern:can't find crate for `extra` -extern mod extra = "fake-crate"; +extern crate extra = "fake-crate"; fn main() { } diff --git a/src/test/compile-fail/use-meta.rc b/src/test/compile-fail/use-meta.rc index 61d18a4a2f7e5..9cb84c5400adc 100644 --- a/src/test/compile-fail/use-meta.rc +++ b/src/test/compile-fail/use-meta.rc @@ -10,4 +10,4 @@ // error-pattern:can't find crate for `std` -extern mod std = "std#bogus"; +extern crate std = "std#bogus"; diff --git a/src/test/compile-fail/view-items-at-top.rs b/src/test/compile-fail/view-items-at-top.rs index c7c96809eecb3..d4b25b6baeb41 100644 --- a/src/test/compile-fail/view-items-at-top.rs +++ b/src/test/compile-fail/view-items-at-top.rs @@ -8,12 +8,12 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; fn f() { } -use extra::net; //~ ERROR `use` and `extern mod` declarations must precede items +use extra::net; //~ ERROR `use` and `extern crate` declarations must precede items fn main() { } diff --git a/src/test/compile-fail/xc-private-method.rs b/src/test/compile-fail/xc-private-method.rs index 4d77e9d2ea405..503c8da70be41 100644 --- a/src/test/compile-fail/xc-private-method.rs +++ b/src/test/compile-fail/xc-private-method.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:xc_private_method_lib.rs -extern mod xc_private_method_lib; +extern crate xc_private_method_lib; fn main() { let _ = xc_private_method_lib::Struct::static_meth_struct(); diff --git a/src/test/compile-fail/xc-private-method2.rs b/src/test/compile-fail/xc-private-method2.rs index d9879fcaba886..978ec39a06e1f 100644 --- a/src/test/compile-fail/xc-private-method2.rs +++ b/src/test/compile-fail/xc-private-method2.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:xc_private_method_lib.rs -extern mod xc_private_method_lib; +extern crate xc_private_method_lib; fn main() { let _ = xc_private_method_lib::Struct{ x: 10 }.meth_struct(); diff --git a/src/test/compile-fail/xcrate-private-by-default.rs b/src/test/compile-fail/xcrate-private-by-default.rs index 8dd05cd00da2c..70b2ea87ac180 100644 --- a/src/test/compile-fail/xcrate-private-by-default.rs +++ b/src/test/compile-fail/xcrate-private-by-default.rs @@ -10,7 +10,7 @@ // aux-build:static_priv_by_default.rs -extern mod static_priv_by_default; +extern crate static_priv_by_default; fn foo() {} diff --git a/src/test/compile-fail/xcrate-unit-struct.rs b/src/test/compile-fail/xcrate-unit-struct.rs index e71a0f05dffc5..cccb7e500213f 100644 --- a/src/test/compile-fail/xcrate-unit-struct.rs +++ b/src/test/compile-fail/xcrate-unit-struct.rs @@ -13,7 +13,7 @@ // Make sure that when we have cross-crate unit structs we don't accidentally // make values out of cross-crate structs that aren't unit. -extern mod xcrate_unit_struct; +extern crate xcrate_unit_struct; fn main() { let _ = xcrate_unit_struct::StructWithFields; //~ ERROR: unresolved name diff --git a/src/test/pretty/raw-str-nonexpr.rs b/src/test/pretty/raw-str-nonexpr.rs index c348c1a430185..026293e752426 100644 --- a/src/test/pretty/raw-str-nonexpr.rs +++ b/src/test/pretty/raw-str-nonexpr.rs @@ -14,6 +14,6 @@ #[feature(asm)]; #[cfg = r#"just parse this"#] -extern mod blah = r##"blah"##; +extern crate blah = r##"blah"##; fn main() { unsafe { asm!(r###"blah"###); } } diff --git a/src/test/run-fail/fail-main.rs b/src/test/run-fail/fail-main.rs index f007e03041c14..d51a2728d3aa3 100644 --- a/src/test/run-fail/fail-main.rs +++ b/src/test/run-fail/fail-main.rs @@ -9,5 +9,5 @@ // except according to those terms. // error-pattern:moop -extern mod extra; +extern crate extra; fn main() { fail!("moop"); } diff --git a/src/test/run-fail/fmt-fail.rs b/src/test/run-fail/fmt-fail.rs index 3bc9014a74c04..ada9e698e657e 100644 --- a/src/test/run-fail/fmt-fail.rs +++ b/src/test/run-fail/fmt-fail.rs @@ -9,6 +9,6 @@ // except according to those terms. // error-pattern:meh -extern mod extra; +extern crate extra; fn main() { let str_var: ~str = ~"meh"; fail!("{}", str_var); } diff --git a/src/test/run-fail/for-each-loop-fail.rs b/src/test/run-fail/for-each-loop-fail.rs index 3c9397fc07ff3..f3e8c9d298ce4 100644 --- a/src/test/run-fail/for-each-loop-fail.rs +++ b/src/test/run-fail/for-each-loop-fail.rs @@ -9,6 +9,6 @@ // except according to those terms. // error-pattern:moop -extern mod extra; +extern crate extra; fn main() { for _ in range(0u, 10u) { fail!("moop"); } } diff --git a/src/test/run-fail/issue-2444.rs b/src/test/run-fail/issue-2444.rs index 16f54e929236a..41221b526f390 100644 --- a/src/test/run-fail/issue-2444.rs +++ b/src/test/run-fail/issue-2444.rs @@ -10,7 +10,7 @@ // error-pattern:explicit failure -extern mod sync; +extern crate sync; use sync::Arc; enum e { e(Arc) } diff --git a/src/test/run-fail/linked-failure.rs b/src/test/run-fail/linked-failure.rs index 38df85e5ce686..fb5fdffffeca5 100644 --- a/src/test/run-fail/linked-failure.rs +++ b/src/test/run-fail/linked-failure.rs @@ -11,7 +11,7 @@ // ignore-test linked failure // error-pattern:1 == 2 -extern mod extra; +extern crate extra; use std::comm; use std::task; diff --git a/src/test/run-fail/morestack2.rs b/src/test/run-fail/morestack2.rs index f998e0cab7605..08ab065598de4 100644 --- a/src/test/run-fail/morestack2.rs +++ b/src/test/run-fail/morestack2.rs @@ -16,7 +16,7 @@ // See the hack in upcall_call_shim_on_c_stack where it messes // with the stack limit. -extern mod extra; +extern crate extra; use std::libc; use std::task; diff --git a/src/test/run-fail/morestack3.rs b/src/test/run-fail/morestack3.rs index c5c563a7aaca0..b15be7402312e 100644 --- a/src/test/run-fail/morestack3.rs +++ b/src/test/run-fail/morestack3.rs @@ -13,7 +13,7 @@ // Just testing unwinding -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-fail/morestack4.rs b/src/test/run-fail/morestack4.rs index 297674bb266fc..7cd19410bfc49 100644 --- a/src/test/run-fail/morestack4.rs +++ b/src/test/run-fail/morestack4.rs @@ -13,7 +13,7 @@ // Just testing unwinding -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-fail/native-failure.rs b/src/test/run-fail/native-failure.rs index 03e7b420c85e7..da00bdf5e0aef 100644 --- a/src/test/run-fail/native-failure.rs +++ b/src/test/run-fail/native-failure.rs @@ -13,7 +13,7 @@ #[no_uv]; -extern mod native; +extern crate native; #[start] fn start(argc: int, argv: **u8) -> int { diff --git a/src/test/run-fail/run-unexported-tests.rs b/src/test/run-fail/run-unexported-tests.rs index 427e606147d50..c25eef44683c3 100644 --- a/src/test/run-fail/run-unexported-tests.rs +++ b/src/test/run-fail/run-unexported-tests.rs @@ -12,7 +12,7 @@ // compile-flags:--test // check-stdout -extern mod extra; +extern crate extra; mod m { pub fn exported() { } diff --git a/src/test/run-fail/spawnfail.rs b/src/test/run-fail/spawnfail.rs index f52193b737604..01bc966e90ad2 100644 --- a/src/test/run-fail/spawnfail.rs +++ b/src/test/run-fail/spawnfail.rs @@ -11,7 +11,7 @@ // ignore-test linked failure // error-pattern:explicit -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-make/bootstrap-from-c-with-green/lib.rs b/src/test/run-make/bootstrap-from-c-with-green/lib.rs index 94119cc0278da..920474ea9bd58 100644 --- a/src/test/run-make/bootstrap-from-c-with-green/lib.rs +++ b/src/test/run-make/bootstrap-from-c-with-green/lib.rs @@ -12,8 +12,8 @@ #[crate_type="dylib"]; #[no_uv]; -extern mod rustuv; -extern mod green; +extern crate rustuv; +extern crate green; #[no_mangle] // this needs to get called from C pub extern "C" fn foo(argc: int, argv: **u8) -> int { diff --git a/src/test/run-make/bootstrap-from-c-with-native/lib.rs b/src/test/run-make/bootstrap-from-c-with-native/lib.rs index 2a783606d944a..2bc0dbb777031 100644 --- a/src/test/run-make/bootstrap-from-c-with-native/lib.rs +++ b/src/test/run-make/bootstrap-from-c-with-native/lib.rs @@ -12,7 +12,7 @@ #[crate_type="dylib"]; #[no_uv]; -extern mod native; +extern crate native; #[no_mangle] // this needs to get called from C pub extern "C" fn foo(argc: int, argv: **u8) -> int { diff --git a/src/test/run-make/c-dynamic-dylib/bar.rs b/src/test/run-make/c-dynamic-dylib/bar.rs index fa21dfac47cdc..37b120decd1a8 100644 --- a/src/test/run-make/c-dynamic-dylib/bar.rs +++ b/src/test/run-make/c-dynamic-dylib/bar.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod foo; +extern crate foo; fn main() { foo::rsfoo(); diff --git a/src/test/run-make/c-dynamic-rlib/bar.rs b/src/test/run-make/c-dynamic-rlib/bar.rs index fa21dfac47cdc..37b120decd1a8 100644 --- a/src/test/run-make/c-dynamic-rlib/bar.rs +++ b/src/test/run-make/c-dynamic-rlib/bar.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod foo; +extern crate foo; fn main() { foo::rsfoo(); diff --git a/src/test/run-make/c-static-dylib/bar.rs b/src/test/run-make/c-static-dylib/bar.rs index fa21dfac47cdc..37b120decd1a8 100644 --- a/src/test/run-make/c-static-dylib/bar.rs +++ b/src/test/run-make/c-static-dylib/bar.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod foo; +extern crate foo; fn main() { foo::rsfoo(); diff --git a/src/test/run-make/c-static-rlib/bar.rs b/src/test/run-make/c-static-rlib/bar.rs index fa21dfac47cdc..37b120decd1a8 100644 --- a/src/test/run-make/c-static-rlib/bar.rs +++ b/src/test/run-make/c-static-rlib/bar.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod foo; +extern crate foo; fn main() { foo::rsfoo(); diff --git a/src/test/run-make/dylib-chain/m2.rs b/src/test/run-make/dylib-chain/m2.rs index 98e9a9ee95071..9adeaa1a20a10 100644 --- a/src/test/run-make/dylib-chain/m2.rs +++ b/src/test/run-make/dylib-chain/m2.rs @@ -9,6 +9,6 @@ // except according to those terms. #[crate_type = "dylib"]; -extern mod m1; +extern crate m1; pub fn m2() { m1::m1() } diff --git a/src/test/run-make/dylib-chain/m3.rs b/src/test/run-make/dylib-chain/m3.rs index b963a4c4f0aef..0a284e52445c8 100644 --- a/src/test/run-make/dylib-chain/m3.rs +++ b/src/test/run-make/dylib-chain/m3.rs @@ -9,6 +9,6 @@ // except according to those terms. #[crate_type = "dylib"]; -extern mod m2; +extern crate m2; pub fn m3() { m2::m2() } diff --git a/src/test/run-make/dylib-chain/m4.rs b/src/test/run-make/dylib-chain/m4.rs index ea2975d6b6ee3..6c2a66858028e 100644 --- a/src/test/run-make/dylib-chain/m4.rs +++ b/src/test/run-make/dylib-chain/m4.rs @@ -8,6 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod m3; +extern crate m3; fn main() { m3::m3() } diff --git a/src/test/run-make/lto-smoke/main.rs b/src/test/run-make/lto-smoke/main.rs index 61ee2481c2cd1..e12ac9e01dc17 100644 --- a/src/test/run-make/lto-smoke/main.rs +++ b/src/test/run-make/lto-smoke/main.rs @@ -8,6 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod lib; +extern crate lib; fn main() {} diff --git a/src/test/run-make/mixing-deps/dylib.rs b/src/test/run-make/mixing-deps/dylib.rs index 9aafd08648029..ae5cce0224528 100644 --- a/src/test/run-make/mixing-deps/dylib.rs +++ b/src/test/run-make/mixing-deps/dylib.rs @@ -9,7 +9,7 @@ // except according to those terms. #[crate_type = "dylib"]; -extern mod both; +extern crate both; use std::cast; diff --git a/src/test/run-make/mixing-deps/prog.rs b/src/test/run-make/mixing-deps/prog.rs index 5d21c01c63137..ed8675eb7064f 100644 --- a/src/test/run-make/mixing-deps/prog.rs +++ b/src/test/run-make/mixing-deps/prog.rs @@ -8,8 +8,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod dylib; -extern mod both; +extern crate dylib; +extern crate both; use std::cast; diff --git a/src/test/run-make/mixing-libs/dylib.rs b/src/test/run-make/mixing-libs/dylib.rs index 8bdff1d8f08df..08a972ef8e6e2 100644 --- a/src/test/run-make/mixing-libs/dylib.rs +++ b/src/test/run-make/mixing-libs/dylib.rs @@ -9,6 +9,6 @@ // except according to those terms. #[crate_type = "dylib"]; -extern mod rlib; +extern crate rlib; pub fn dylib() { rlib::rlib() } diff --git a/src/test/run-make/mixing-libs/prog.rs b/src/test/run-make/mixing-libs/prog.rs index 9a97ddfd1b594..5e1a4274756c3 100644 --- a/src/test/run-make/mixing-libs/prog.rs +++ b/src/test/run-make/mixing-libs/prog.rs @@ -8,8 +8,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod dylib; -extern mod rlib; +extern crate dylib; +extern crate rlib; fn main() { dylib::dylib(); diff --git a/src/test/run-make/prefer-dylib/foo.rs b/src/test/run-make/prefer-dylib/foo.rs index 2c22cea09aa29..858ef492acef5 100644 --- a/src/test/run-make/prefer-dylib/foo.rs +++ b/src/test/run-make/prefer-dylib/foo.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod bar; +extern crate bar; fn main() { bar::bar(); diff --git a/src/test/run-make/prefer-rlib/foo.rs b/src/test/run-make/prefer-rlib/foo.rs index 2c22cea09aa29..858ef492acef5 100644 --- a/src/test/run-make/prefer-rlib/foo.rs +++ b/src/test/run-make/prefer-rlib/foo.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod bar; +extern crate bar; fn main() { bar::bar(); diff --git a/src/test/run-make/rlib-chain/m2.rs b/src/test/run-make/rlib-chain/m2.rs index 612e59d10827d..40c1575d0695c 100644 --- a/src/test/run-make/rlib-chain/m2.rs +++ b/src/test/run-make/rlib-chain/m2.rs @@ -9,6 +9,6 @@ // except according to those terms. #[crate_type = "rlib"]; -extern mod m1; +extern crate m1; pub fn m2() { m1::m1() } diff --git a/src/test/run-make/rlib-chain/m3.rs b/src/test/run-make/rlib-chain/m3.rs index 7545eed6f01b2..3d3be554757bb 100644 --- a/src/test/run-make/rlib-chain/m3.rs +++ b/src/test/run-make/rlib-chain/m3.rs @@ -9,6 +9,6 @@ // except according to those terms. #[crate_type = "rlib"]; -extern mod m2; +extern crate m2; pub fn m3() { m2::m2() } diff --git a/src/test/run-make/rlib-chain/m4.rs b/src/test/run-make/rlib-chain/m4.rs index ea2975d6b6ee3..6c2a66858028e 100644 --- a/src/test/run-make/rlib-chain/m4.rs +++ b/src/test/run-make/rlib-chain/m4.rs @@ -8,6 +8,6 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod m3; +extern crate m3; fn main() { m3::m3() } diff --git a/src/test/run-make/simple-dylib/foo.rs b/src/test/run-make/simple-dylib/foo.rs index 2c22cea09aa29..858ef492acef5 100644 --- a/src/test/run-make/simple-dylib/foo.rs +++ b/src/test/run-make/simple-dylib/foo.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod bar; +extern crate bar; fn main() { bar::bar(); diff --git a/src/test/run-make/simple-rlib/foo.rs b/src/test/run-make/simple-rlib/foo.rs index 2c22cea09aa29..858ef492acef5 100644 --- a/src/test/run-make/simple-rlib/foo.rs +++ b/src/test/run-make/simple-rlib/foo.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod bar; +extern crate bar; fn main() { bar::bar(); diff --git a/src/test/run-make/static-unwinding/main.rs b/src/test/run-make/static-unwinding/main.rs index c47d20583936b..08777490f212b 100644 --- a/src/test/run-make/static-unwinding/main.rs +++ b/src/test/run-make/static-unwinding/main.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod lib; +extern crate lib; use std::task; diff --git a/src/test/run-pass-fulldeps/macro-crate-outlive-expansion-phase.rs b/src/test/run-pass-fulldeps/macro-crate-outlive-expansion-phase.rs index a71cc465e88dc..80ebf54559fbe 100644 --- a/src/test/run-pass-fulldeps/macro-crate-outlive-expansion-phase.rs +++ b/src/test/run-pass-fulldeps/macro-crate-outlive-expansion-phase.rs @@ -16,6 +16,6 @@ #[feature(phase)]; #[phase(syntax)] -extern mod macro_crate_outlive_expansion_phase; +extern crate macro_crate_outlive_expansion_phase; pub fn main() {} diff --git a/src/test/run-pass-fulldeps/macro-crate.rs b/src/test/run-pass-fulldeps/macro-crate.rs index b9077ab59d701..6738bd245e341 100644 --- a/src/test/run-pass-fulldeps/macro-crate.rs +++ b/src/test/run-pass-fulldeps/macro-crate.rs @@ -16,7 +16,7 @@ #[feature(phase)]; #[phase(syntax)] -extern mod macro_crate_test; +extern crate macro_crate_test; pub fn main() { assert_eq!(1, make_a_1!()); diff --git a/src/test/run-pass-fulldeps/qquote.rs b/src/test/run-pass-fulldeps/qquote.rs index 662ecfb46d345..0e31cbd2e955c 100644 --- a/src/test/run-pass-fulldeps/qquote.rs +++ b/src/test/run-pass-fulldeps/qquote.rs @@ -13,8 +13,8 @@ #[feature(quote)]; -extern mod extra; -extern mod syntax; +extern crate extra; +extern crate syntax; use std::io::*; diff --git a/src/test/run-pass-fulldeps/quote-tokens.rs b/src/test/run-pass-fulldeps/quote-tokens.rs index 114e62fb80a43..b11515ac24bd9 100644 --- a/src/test/run-pass-fulldeps/quote-tokens.rs +++ b/src/test/run-pass-fulldeps/quote-tokens.rs @@ -13,7 +13,7 @@ #[feature(quote)]; #[feature(managed_boxes)]; -extern mod syntax; +extern crate syntax; use syntax::ext::base::ExtCtxt; diff --git a/src/test/run-pass-fulldeps/quote-unused-sp-no-warning.rs b/src/test/run-pass-fulldeps/quote-unused-sp-no-warning.rs index a27b4e302388c..ac8d361bf5aa4 100644 --- a/src/test/run-pass-fulldeps/quote-unused-sp-no-warning.rs +++ b/src/test/run-pass-fulldeps/quote-unused-sp-no-warning.rs @@ -13,7 +13,7 @@ #[feature(quote)]; #[deny(unused_variable)]; -extern mod syntax; +extern crate syntax; use syntax::ext::base::ExtCtxt; diff --git a/src/test/run-pass-fulldeps/syntax-extension-fourcc.rs b/src/test/run-pass-fulldeps/syntax-extension-fourcc.rs index ab25946b64381..a6f118d77faab 100644 --- a/src/test/run-pass-fulldeps/syntax-extension-fourcc.rs +++ b/src/test/run-pass-fulldeps/syntax-extension-fourcc.rs @@ -16,7 +16,7 @@ #[feature(phase)]; #[phase(syntax)] -extern mod fourcc; +extern crate fourcc; static static_val: u32 = fourcc!("foo "); static static_val_be: u32 = fourcc!("foo ", big); diff --git a/src/test/run-pass/anon-extern-mod-cross-crate-2.rs b/src/test/run-pass/anon-extern-mod-cross-crate-2.rs index 7187438cc6d27..8cadf4825f684 100644 --- a/src/test/run-pass/anon-extern-mod-cross-crate-2.rs +++ b/src/test/run-pass/anon-extern-mod-cross-crate-2.rs @@ -11,7 +11,7 @@ // ignore-fast // ignore-pretty // aux-build:anon-extern-mod-cross-crate-1.rs -extern mod anonexternmod; +extern crate anonexternmod; use anonexternmod::rust_get_test_int; diff --git a/src/test/run-pass/anon_trait_static_method_exe.rs b/src/test/run-pass/anon_trait_static_method_exe.rs index c7b35c7f366fd..c66a8a9d2ca45 100644 --- a/src/test/run-pass/anon_trait_static_method_exe.rs +++ b/src/test/run-pass/anon_trait_static_method_exe.rs @@ -11,7 +11,7 @@ // ignore-fast - check-fast doesn't understand aux-build // aux-build:anon_trait_static_method_lib.rs -extern mod anon_trait_static_method_lib; +extern crate anon_trait_static_method_lib; use anon_trait_static_method_lib::Foo; pub fn main() { diff --git a/src/test/run-pass/attr-before-view-item.rs b/src/test/run-pass/attr-before-view-item.rs index 316f8fa0f61f4..30d4315f081ac 100644 --- a/src/test/run-pass/attr-before-view-item.rs +++ b/src/test/run-pass/attr-before-view-item.rs @@ -11,7 +11,7 @@ // error-pattern:expected item #[foo = "bar"] -extern mod extra; +extern crate extra; pub fn main() { } diff --git a/src/test/run-pass/attr-before-view-item2.rs b/src/test/run-pass/attr-before-view-item2.rs index 0721544aa0dc8..0d099841c0b39 100644 --- a/src/test/run-pass/attr-before-view-item2.rs +++ b/src/test/run-pass/attr-before-view-item2.rs @@ -12,7 +12,7 @@ mod m { #[foo = "bar"] - extern mod extra; + extern crate extra; } pub fn main() { diff --git a/src/test/run-pass/auto-encode.rs b/src/test/run-pass/auto-encode.rs index 6c511bcdaf08b..caf9a92bba3b4 100644 --- a/src/test/run-pass/auto-encode.rs +++ b/src/test/run-pass/auto-encode.rs @@ -13,7 +13,7 @@ #[feature(managed_boxes)]; -extern mod extra; +extern crate extra; // These tests used to be separate files, but I wanted to refactor all // the common code. diff --git a/src/test/run-pass/bind-by-move.rs b/src/test/run-pass/bind-by-move.rs index 698b7b43d0834..e8cbd03743441 100644 --- a/src/test/run-pass/bind-by-move.rs +++ b/src/test/run-pass/bind-by-move.rs @@ -9,7 +9,7 @@ // except according to those terms. // ignore-fast -extern mod sync; +extern crate sync; use sync::Arc; fn dispose(_x: Arc) { } diff --git a/src/test/run-pass/bitv-perf-test.rs b/src/test/run-pass/bitv-perf-test.rs index 6525e8797508d..20b3ca0b3bae7 100644 --- a/src/test/run-pass/bitv-perf-test.rs +++ b/src/test/run-pass/bitv-perf-test.rs @@ -10,7 +10,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod collections; +extern crate collections; use collections::Bitv; fn bitv_test() { diff --git a/src/test/run-pass/block-arg-call-as.rs b/src/test/run-pass/block-arg-call-as.rs index 5d5a5843a646f..c149afb87822c 100644 --- a/src/test/run-pass/block-arg-call-as.rs +++ b/src/test/run-pass/block-arg-call-as.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; fn asSendfn(f: proc() -> uint) -> uint { return f(); diff --git a/src/test/run-pass/builtin-superkinds-capabilities-xc.rs b/src/test/run-pass/builtin-superkinds-capabilities-xc.rs index ce633b118bb7a..b67edf245b2d9 100644 --- a/src/test/run-pass/builtin-superkinds-capabilities-xc.rs +++ b/src/test/run-pass/builtin-superkinds-capabilities-xc.rs @@ -15,7 +15,7 @@ // Tests "capabilities" granted by traits with super-builtin-kinds, // even when using them cross-crate. -extern mod trait_superkinds_in_metadata; +extern crate trait_superkinds_in_metadata; use trait_superkinds_in_metadata::{RequiresRequiresFreezeAndSend, RequiresFreeze}; #[deriving(Eq)] diff --git a/src/test/run-pass/builtin-superkinds-in-metadata.rs b/src/test/run-pass/builtin-superkinds-in-metadata.rs index eeb4d7f6dd516..8cecd5019a395 100644 --- a/src/test/run-pass/builtin-superkinds-in-metadata.rs +++ b/src/test/run-pass/builtin-superkinds-in-metadata.rs @@ -14,7 +14,7 @@ // Tests (correct) usage of trait super-builtin-kinds cross-crate. -extern mod trait_superkinds_in_metadata; +extern crate trait_superkinds_in_metadata; use trait_superkinds_in_metadata::{RequiresRequiresFreezeAndSend, RequiresFreeze}; use trait_superkinds_in_metadata::{RequiresPod}; diff --git a/src/test/run-pass/capturing-logging.rs b/src/test/run-pass/capturing-logging.rs index 37557d0ab7d2a..2473911483ce8 100644 --- a/src/test/run-pass/capturing-logging.rs +++ b/src/test/run-pass/capturing-logging.rs @@ -13,7 +13,7 @@ // exec-env:RUST_LOG=info #[no_uv]; -extern mod native; +extern crate native; use std::fmt; use std::io::{PortReader, ChanWriter}; diff --git a/src/test/run-pass/cci_borrow.rs b/src/test/run-pass/cci_borrow.rs index c7e3de71fe2be..cb77c63d4511a 100644 --- a/src/test/run-pass/cci_borrow.rs +++ b/src/test/run-pass/cci_borrow.rs @@ -13,7 +13,7 @@ #[feature(managed_boxes)]; -extern mod cci_borrow_lib; +extern crate cci_borrow_lib; use cci_borrow_lib::foo; pub fn main() { diff --git a/src/test/run-pass/cci_capture_clause.rs b/src/test/run-pass/cci_capture_clause.rs index f72f06e2a7b3b..fa96f65243ead 100644 --- a/src/test/run-pass/cci_capture_clause.rs +++ b/src/test/run-pass/cci_capture_clause.rs @@ -14,7 +14,7 @@ // This test makes sure we can do cross-crate inlining on functions // that use capture clauses. -extern mod cci_capture_clause; +extern crate cci_capture_clause; pub fn main() { cci_capture_clause::foo(()).recv() diff --git a/src/test/run-pass/cci_impl_exe.rs b/src/test/run-pass/cci_impl_exe.rs index f297b54c54d4b..e5e1736044c5d 100644 --- a/src/test/run-pass/cci_impl_exe.rs +++ b/src/test/run-pass/cci_impl_exe.rs @@ -11,7 +11,7 @@ // ignore-fast - check-fast doesn't understand aux-build // aux-build:cci_impl_lib.rs -extern mod cci_impl_lib; +extern crate cci_impl_lib; use cci_impl_lib::uint_helpers; pub fn main() { diff --git a/src/test/run-pass/cci_iter_exe.rs b/src/test/run-pass/cci_iter_exe.rs index ce9687e6b9a03..41717177f75bc 100644 --- a/src/test/run-pass/cci_iter_exe.rs +++ b/src/test/run-pass/cci_iter_exe.rs @@ -11,7 +11,7 @@ // ignore-fast - check-fast doesn't understand aux-build // aux-build:cci_iter_lib.rs -extern mod cci_iter_lib; +extern crate cci_iter_lib; pub fn main() { //let bt0 = sys::rusti::frame_address(1u32); diff --git a/src/test/run-pass/cci_nested_exe.rs b/src/test/run-pass/cci_nested_exe.rs index f5f00e4c279d7..3810f7919ac26 100644 --- a/src/test/run-pass/cci_nested_exe.rs +++ b/src/test/run-pass/cci_nested_exe.rs @@ -13,7 +13,7 @@ #[feature(globs, managed_boxes)]; -extern mod cci_nested_lib; +extern crate cci_nested_lib; use cci_nested_lib::*; pub fn main() { diff --git a/src/test/run-pass/cci_no_inline_exe.rs b/src/test/run-pass/cci_no_inline_exe.rs index d0e97b9835127..faa2a35011704 100644 --- a/src/test/run-pass/cci_no_inline_exe.rs +++ b/src/test/run-pass/cci_no_inline_exe.rs @@ -11,7 +11,7 @@ // ignore-fast - check-fast doesn't understand aux-build // aux-build:cci_no_inline_lib.rs -extern mod cci_no_inline_lib; +extern crate cci_no_inline_lib; use cci_no_inline_lib::iter; pub fn main() { diff --git a/src/test/run-pass/cfg_inner_static.rs b/src/test/run-pass/cfg_inner_static.rs index 977d8a2b0a77a..08951dfd50e2e 100644 --- a/src/test/run-pass/cfg_inner_static.rs +++ b/src/test/run-pass/cfg_inner_static.rs @@ -11,7 +11,7 @@ // aux-build:cfg_inner_static.rs // ignore-fast -extern mod cfg_inner_static; +extern crate cfg_inner_static; pub fn main() { cfg_inner_static::foo(); diff --git a/src/test/run-pass/class-cast-to-trait-cross-crate-2.rs b/src/test/run-pass/class-cast-to-trait-cross-crate-2.rs index d9fa5507cf121..746342ae97345 100644 --- a/src/test/run-pass/class-cast-to-trait-cross-crate-2.rs +++ b/src/test/run-pass/class-cast-to-trait-cross-crate-2.rs @@ -10,7 +10,7 @@ // ignore-fast // aux-build:cci_class_cast.rs -extern mod cci_class_cast; +extern crate cci_class_cast; use std::to_str::ToStr; use cci_class_cast::kitty::cat; diff --git a/src/test/run-pass/class-implement-trait-cross-crate.rs b/src/test/run-pass/class-implement-trait-cross-crate.rs index 908c3afda1231..caa4a3b2feb6f 100644 --- a/src/test/run-pass/class-implement-trait-cross-crate.rs +++ b/src/test/run-pass/class-implement-trait-cross-crate.rs @@ -10,7 +10,7 @@ // ignore-fast // aux-build:cci_class_trait.rs -extern mod cci_class_trait; +extern crate cci_class_trait; use cci_class_trait::animals::noisy; struct cat { diff --git a/src/test/run-pass/class-method-cross-crate.rs b/src/test/run-pass/class-method-cross-crate.rs index 41143d7ade6e7..8ee367d281f2c 100644 --- a/src/test/run-pass/class-method-cross-crate.rs +++ b/src/test/run-pass/class-method-cross-crate.rs @@ -10,7 +10,7 @@ // ignore-fast // aux-build:cci_class_2.rs -extern mod cci_class_2; +extern crate cci_class_2; use cci_class_2::kitties::cat; pub fn main() { diff --git a/src/test/run-pass/class-methods-cross-crate.rs b/src/test/run-pass/class-methods-cross-crate.rs index 2975843ae5770..ca3b491844f12 100644 --- a/src/test/run-pass/class-methods-cross-crate.rs +++ b/src/test/run-pass/class-methods-cross-crate.rs @@ -10,7 +10,7 @@ // ignore-fast // aux-build:cci_class_3.rs -extern mod cci_class_3; +extern crate cci_class_3; use cci_class_3::kitties::cat; pub fn main() { diff --git a/src/test/run-pass/class-poly-methods-cross-crate.rs b/src/test/run-pass/class-poly-methods-cross-crate.rs index bc9e73b35653f..671d7a403531b 100644 --- a/src/test/run-pass/class-poly-methods-cross-crate.rs +++ b/src/test/run-pass/class-poly-methods-cross-crate.rs @@ -10,7 +10,7 @@ // ignore-fast // aux-build:cci_class_6.rs -extern mod cci_class_6; +extern crate cci_class_6; use cci_class_6::kitties::cat; pub fn main() { diff --git a/src/test/run-pass/classes-cross-crate.rs b/src/test/run-pass/classes-cross-crate.rs index 8c7e0e3febb93..2e1d19b9dda2d 100644 --- a/src/test/run-pass/classes-cross-crate.rs +++ b/src/test/run-pass/classes-cross-crate.rs @@ -10,7 +10,7 @@ // ignore-fast // aux-build:cci_class_4.rs -extern mod cci_class_4; +extern crate cci_class_4; use cci_class_4::kitties::cat; pub fn main() { diff --git a/src/test/run-pass/classes-simple-cross-crate.rs b/src/test/run-pass/classes-simple-cross-crate.rs index 8546f79c1e8a6..6d816e725b9b9 100644 --- a/src/test/run-pass/classes-simple-cross-crate.rs +++ b/src/test/run-pass/classes-simple-cross-crate.rs @@ -10,7 +10,7 @@ // ignore-fast // aux-build:cci_class.rs -extern mod cci_class; +extern crate cci_class; use cci_class::kitties::cat; pub fn main() { diff --git a/src/test/run-pass/clone-with-exterior.rs b/src/test/run-pass/clone-with-exterior.rs index 6fab709543a0a..091cebcc0633b 100644 --- a/src/test/run-pass/clone-with-exterior.rs +++ b/src/test/run-pass/clone-with-exterior.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use std::task::spawn; struct Pair { diff --git a/src/test/run-pass/const-cross-crate-const.rs b/src/test/run-pass/const-cross-crate-const.rs index 4f8db9a3ca2d8..c8dc98baac6be 100644 --- a/src/test/run-pass/const-cross-crate-const.rs +++ b/src/test/run-pass/const-cross-crate-const.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:cci_const.rs -extern mod cci_const; +extern crate cci_const; static foo: &'static str = cci_const::foopy; static a: uint = cci_const::uint_val; static b: uint = cci_const::uint_expr + 5; diff --git a/src/test/run-pass/const-cross-crate-extern.rs b/src/test/run-pass/const-cross-crate-extern.rs index 22d2c908b37bb..75a0bac0293ca 100644 --- a/src/test/run-pass/const-cross-crate-extern.rs +++ b/src/test/run-pass/const-cross-crate-extern.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:cci_const.rs -extern mod cci_const; +extern crate cci_const; use cci_const::bar; static foo: extern "C" fn() = bar; diff --git a/src/test/run-pass/crate-method-reexport-grrrrrrr.rs b/src/test/run-pass/crate-method-reexport-grrrrrrr.rs index 0993105c51261..1b563d33433c3 100644 --- a/src/test/run-pass/crate-method-reexport-grrrrrrr.rs +++ b/src/test/run-pass/crate-method-reexport-grrrrrrr.rs @@ -17,7 +17,7 @@ // ignore-fast // aux-build:crate-method-reexport-grrrrrrr2.rs -extern mod crate_method_reexport_grrrrrrr2; +extern crate crate_method_reexport_grrrrrrr2; pub fn main() { use crate_method_reexport_grrrrrrr2::rust::add; diff --git a/src/test/run-pass/crateresolve1.rs b/src/test/run-pass/crateresolve1.rs index dec983a180fb2..bf13e66690cd1 100644 --- a/src/test/run-pass/crateresolve1.rs +++ b/src/test/run-pass/crateresolve1.rs @@ -13,7 +13,7 @@ // aux-build:crateresolve1-2.rs // aux-build:crateresolve1-3.rs -extern mod crateresolve1 = "crateresolve1#0.2"; +extern crate crateresolve1 = "crateresolve1#0.2"; pub fn main() { assert_eq!(crateresolve1::f(), 20); diff --git a/src/test/run-pass/crateresolve2.rs b/src/test/run-pass/crateresolve2.rs index 97bcd56178f9c..1419d68ad6837 100644 --- a/src/test/run-pass/crateresolve2.rs +++ b/src/test/run-pass/crateresolve2.rs @@ -14,17 +14,17 @@ // aux-build:crateresolve2-3.rs mod a { - extern mod crateresolve2 = "crateresolve2#0.1"; + extern crate crateresolve2 = "crateresolve2#0.1"; pub fn f() { assert!(crateresolve2::f() == 10); } } mod b { - extern mod crateresolve2 = "crateresolve2#0.2"; + extern crate crateresolve2 = "crateresolve2#0.2"; pub fn f() { assert!(crateresolve2::f() == 20); } } mod c { - extern mod crateresolve2 = "crateresolve2#0.3"; + extern crate crateresolve2 = "crateresolve2#0.3"; pub fn f() { assert!(crateresolve2::f() == 30); } } diff --git a/src/test/run-pass/crateresolve3.rs b/src/test/run-pass/crateresolve3.rs index 4f87b9bb02f41..fd83c8f515a51 100644 --- a/src/test/run-pass/crateresolve3.rs +++ b/src/test/run-pass/crateresolve3.rs @@ -16,12 +16,12 @@ // as long as no name collision on invoked functions. mod a { - extern mod crateresolve3 = "crateresolve3#0.1"; + extern crate crateresolve3 = "crateresolve3#0.1"; pub fn f() { assert!(crateresolve3::f() == 10); } } mod b { - extern mod crateresolve3 = "crateresolve3#0.2"; + extern crate crateresolve3 = "crateresolve3#0.2"; pub fn f() { assert!(crateresolve3::g() == 20); } } diff --git a/src/test/run-pass/crateresolve4.rs b/src/test/run-pass/crateresolve4.rs index 3e2d19f2a8dd9..3243c909e03a9 100644 --- a/src/test/run-pass/crateresolve4.rs +++ b/src/test/run-pass/crateresolve4.rs @@ -15,12 +15,12 @@ // aux-build:crateresolve4b-2.rs pub mod a { - extern mod crateresolve4b = "crateresolve4b#0.1"; + extern crate crateresolve4b = "crateresolve4b#0.1"; pub fn f() { assert!(crateresolve4b::f() == 20); } } pub mod b { - extern mod crateresolve4b = "crateresolve4b#0.2"; + extern crate crateresolve4b = "crateresolve4b#0.2"; pub fn f() { assert!(crateresolve4b::g() == 10); } } diff --git a/src/test/run-pass/crateresolve5.rs b/src/test/run-pass/crateresolve5.rs index 24a9f2286b4aa..ca690b9089bb5 100644 --- a/src/test/run-pass/crateresolve5.rs +++ b/src/test/run-pass/crateresolve5.rs @@ -12,8 +12,8 @@ // aux-build:crateresolve5-1.rs // aux-build:crateresolve5-2.rs -extern mod cr5_1 = "crateresolve5#0.1"; -extern mod cr5_2 = "crateresolve5#0.2"; +extern crate cr5_1 = "crateresolve5#0.1"; +extern crate cr5_2 = "crateresolve5#0.2"; pub fn main() { // Structural types can be used between two versions of the same crate diff --git a/src/test/run-pass/crateresolve8.rs b/src/test/run-pass/crateresolve8.rs index 4d1cba92f8079..46ccb01f66048 100644 --- a/src/test/run-pass/crateresolve8.rs +++ b/src/test/run-pass/crateresolve8.rs @@ -13,8 +13,8 @@ #[crate_id="crateresolve8#0.1"]; -extern mod crateresolve8 = "crateresolve8#0.1"; -//extern mod crateresolve8(vers = "0.1"); +extern crate crateresolve8 = "crateresolve8#0.1"; +//extern crate crateresolve8(vers = "0.1"); pub fn main() { assert_eq!(crateresolve8::f(), 20); diff --git a/src/test/run-pass/cross-crate-const-pat.rs b/src/test/run-pass/cross-crate-const-pat.rs index 1949c07ce59c9..9e3a43469f2ef 100644 --- a/src/test/run-pass/cross-crate-const-pat.rs +++ b/src/test/run-pass/cross-crate-const-pat.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:cci_const.rs -extern mod cci_const; +extern crate cci_const; pub fn main() { let x = cci_const::uint_val; diff --git a/src/test/run-pass/cross-crate-newtype-struct-pat.rs b/src/test/run-pass/cross-crate-newtype-struct-pat.rs index ddebd5da114ec..8988ee52b1649 100644 --- a/src/test/run-pass/cross-crate-newtype-struct-pat.rs +++ b/src/test/run-pass/cross-crate-newtype-struct-pat.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:newtype_struct_xc.rs -extern mod newtype_struct_xc; +extern crate newtype_struct_xc; pub fn main() { let x = newtype_struct_xc::Au(21); diff --git a/src/test/run-pass/deriving-encodable-decodable.rs b/src/test/run-pass/deriving-encodable-decodable.rs index 177459c0321bc..50ccac793c265 100644 --- a/src/test/run-pass/deriving-encodable-decodable.rs +++ b/src/test/run-pass/deriving-encodable-decodable.rs @@ -16,7 +16,7 @@ #[feature(struct_variant, managed_boxes)]; -extern mod serialize; +extern crate serialize; use std::io::MemWriter; use std::rand::{random, Rand}; diff --git a/src/test/run-pass/deriving-global.rs b/src/test/run-pass/deriving-global.rs index ca53636b0a629..544a8c2b00af8 100644 --- a/src/test/run-pass/deriving-global.rs +++ b/src/test/run-pass/deriving-global.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -// ignore-fast #7103 `extern mod` does not work on check-fast +// ignore-fast #7103 `extern crate` does not work on check-fast // ignore-pretty - does not converge // Copyright 2013-2014 The Rust Project Developers. See the COPYRIGHT @@ -21,7 +21,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod serialize; // {En,De}codable +extern crate serialize; // {En,De}codable mod submod { // if any of these are implemented without global calls for any // function calls, then being in a submodule will (correctly) diff --git a/src/test/run-pass/duplicate-use.rs b/src/test/run-pass/duplicate-use.rs index 4362792ceebaa..c710eb5eafb0f 100644 --- a/src/test/run-pass/duplicate-use.rs +++ b/src/test/run-pass/duplicate-use.rs @@ -10,7 +10,7 @@ // ignore-test -extern mod extra; +extern crate extra; use list = extra::oldmap::chained; use extra::list; diff --git a/src/test/run-pass/duplicated-external-mods.rs b/src/test/run-pass/duplicated-external-mods.rs index 0a975e3f89d5c..b50fd7cbb34cd 100644 --- a/src/test/run-pass/duplicated-external-mods.rs +++ b/src/test/run-pass/duplicated-external-mods.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:anon-extern-mod-cross-crate-1.rs // aux-build:anon-extern-mod-cross-crate-1.rs -extern mod anonexternmod; +extern crate anonexternmod; pub fn main() { } diff --git a/src/test/run-pass/explicit-self-generic.rs b/src/test/run-pass/explicit-self-generic.rs index fb533a3de5858..a3c5256c2d365 100644 --- a/src/test/run-pass/explicit-self-generic.rs +++ b/src/test/run-pass/explicit-self-generic.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; /** * A function that returns a hash of a value diff --git a/src/test/run-pass/explicit_self_xcrate_exe.rs b/src/test/run-pass/explicit_self_xcrate_exe.rs index dc00bce141cc5..ce805fcf73713 100644 --- a/src/test/run-pass/explicit_self_xcrate_exe.rs +++ b/src/test/run-pass/explicit_self_xcrate_exe.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:explicit_self_xcrate.rs -extern mod explicit_self_xcrate; +extern crate explicit_self_xcrate; use explicit_self_xcrate::{Foo, Bar}; pub fn main() { diff --git a/src/test/run-pass/extern-calling-convention-test.rs b/src/test/run-pass/extern-calling-convention-test.rs index 92726f9a2a8ef..b895466cf7ebe 100644 --- a/src/test/run-pass/extern-calling-convention-test.rs +++ b/src/test/run-pass/extern-calling-convention-test.rs @@ -11,7 +11,7 @@ // ignore-fast: aux-build not compatible with fast // aux-build:extern_calling_convention.rs -extern mod extern_calling_convention; +extern crate extern_calling_convention; use extern_calling_convention::foo; diff --git a/src/test/run-pass/extern-crosscrate.rs b/src/test/run-pass/extern-crosscrate.rs index 30ea3bc260ca7..ccd79600a15a7 100644 --- a/src/test/run-pass/extern-crosscrate.rs +++ b/src/test/run-pass/extern-crosscrate.rs @@ -11,7 +11,7 @@ // ignore-fast //aux-build:extern-crosscrate-source.rs -extern mod externcallback = "externcallback#0.1"; +extern crate externcallback = "externcallback#0.1"; fn fact(n: uint) -> uint { unsafe { diff --git a/src/test/run-pass/extern-foreign-crate.rs b/src/test/run-pass/extern-foreign-crate.rs index 8949734b80e48..1c5df4acf73c7 100644 --- a/src/test/run-pass/extern-foreign-crate.rs +++ b/src/test/run-pass/extern-foreign-crate.rs @@ -9,6 +9,6 @@ // except according to those terms. extern crate extra; -extern mod mystd = "std"; +extern crate mystd = "std"; pub fn main() {} diff --git a/src/test/run-pass/extern-mod-ordering-exe.rs b/src/test/run-pass/extern-mod-ordering-exe.rs index 87c53f5ff573f..f228c0c099253 100644 --- a/src/test/run-pass/extern-mod-ordering-exe.rs +++ b/src/test/run-pass/extern-mod-ordering-exe.rs @@ -11,7 +11,7 @@ // aux-build:extern_mod_ordering_lib.rs // ignore-fast -extern mod extern_mod_ordering_lib; +extern crate extern_mod_ordering_lib; use extern_mod_ordering_lib::extern_mod_ordering_lib; diff --git a/src/test/run-pass/extern-mod-syntax.rs b/src/test/run-pass/extern-mod-syntax.rs index ff798991c8785..fdea2716d5f29 100644 --- a/src/test/run-pass/extern-mod-syntax.rs +++ b/src/test/run-pass/extern-mod-syntax.rs @@ -12,7 +12,7 @@ #[allow(unused_imports)]; -extern mod extra; +extern crate extra; use extra::json::Object; pub fn main() { diff --git a/src/test/run-pass/float-nan.rs b/src/test/run-pass/float-nan.rs index 9035176a267b1..66c84d52745cd 100644 --- a/src/test/run-pass/float-nan.rs +++ b/src/test/run-pass/float-nan.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use std::num::Float; diff --git a/src/test/run-pass/foreign-fn-linkname.rs b/src/test/run-pass/foreign-fn-linkname.rs index aeba5c0ec97e1..b9d8d622731d3 100644 --- a/src/test/run-pass/foreign-fn-linkname.rs +++ b/src/test/run-pass/foreign-fn-linkname.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; mod libc { use std::libc::{c_char, size_t}; diff --git a/src/test/run-pass/generic-default-type-params-cross-crate.rs b/src/test/run-pass/generic-default-type-params-cross-crate.rs index 2fc6570f77dbd..412e780f8a23b 100644 --- a/src/test/run-pass/generic-default-type-params-cross-crate.rs +++ b/src/test/run-pass/generic-default-type-params-cross-crate.rs @@ -15,7 +15,7 @@ #[allow(default_type_param_usage)]; -extern mod default_type_params_xc; +extern crate default_type_params_xc; struct Vec; diff --git a/src/test/run-pass/getopts_ref.rs b/src/test/run-pass/getopts_ref.rs index d62050e0f8676..55ecf919b7240 100644 --- a/src/test/run-pass/getopts_ref.rs +++ b/src/test/run-pass/getopts_ref.rs @@ -10,7 +10,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod getopts; +extern crate getopts; use getopts::{optopt, getopts}; diff --git a/src/test/run-pass/glob-std.rs b/src/test/run-pass/glob-std.rs index 4d889b7f00d0a..c1e6f04e67d0d 100644 --- a/src/test/run-pass/glob-std.rs +++ b/src/test/run-pass/glob-std.rs @@ -8,11 +8,11 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -// ignore-fast check-fast doesn't like 'extern mod extra' +// ignore-fast check-fast doesn't like 'extern crate extra' // ignore-win32 TempDir may cause IoError on windows: #10462 -extern mod extra; -extern mod glob; +extern crate extra; +extern crate glob; use glob::glob; use extra::tempfile::TempDir; diff --git a/src/test/run-pass/impl-privacy-xc-1.rs b/src/test/run-pass/impl-privacy-xc-1.rs index efdc9e8655c43..9665d4d684d9c 100644 --- a/src/test/run-pass/impl-privacy-xc-1.rs +++ b/src/test/run-pass/impl-privacy-xc-1.rs @@ -11,7 +11,7 @@ // aux-build:impl_privacy_xc_1.rs // ignore-fast -extern mod impl_privacy_xc_1; +extern crate impl_privacy_xc_1; pub fn main() { let fish = impl_privacy_xc_1::Fish { x: 1 }; diff --git a/src/test/run-pass/impl-privacy-xc-2.rs b/src/test/run-pass/impl-privacy-xc-2.rs index 829c7eb5f29b0..8e67a5c74c5d8 100644 --- a/src/test/run-pass/impl-privacy-xc-2.rs +++ b/src/test/run-pass/impl-privacy-xc-2.rs @@ -11,7 +11,7 @@ // aux-build:impl_privacy_xc_2.rs // ignore-fast -extern mod impl_privacy_xc_2; +extern crate impl_privacy_xc_2; pub fn main() { let fish1 = impl_privacy_xc_2::Fish { x: 1 }; diff --git a/src/test/run-pass/import-glob-crate.rs b/src/test/run-pass/import-glob-crate.rs index 1815497d205cd..f2117efb0bbe6 100644 --- a/src/test/run-pass/import-glob-crate.rs +++ b/src/test/run-pass/import-glob-crate.rs @@ -13,7 +13,7 @@ #[feature(globs)]; #[allow(dead_assignment)]; -extern mod extra; +extern crate extra; use std::vec::*; pub fn main() { diff --git a/src/test/run-pass/infinite-loops.rs b/src/test/run-pass/infinite-loops.rs index ff3937784b8c6..50091c94a76b6 100644 --- a/src/test/run-pass/infinite-loops.rs +++ b/src/test/run-pass/infinite-loops.rs @@ -14,7 +14,7 @@ */ // ignore-test -extern mod extra; +extern crate extra; fn loopy(n: int) { if n > 0 { spawn(proc() { loopy(n - 1) }); spawn(proc() { loopy(n - 1) }); } diff --git a/src/test/run-pass/inner-static.rs b/src/test/run-pass/inner-static.rs index ec5fea3b6ed35..3e04a8a3922e3 100644 --- a/src/test/run-pass/inner-static.rs +++ b/src/test/run-pass/inner-static.rs @@ -11,7 +11,7 @@ // aux-build:inner_static.rs // ignore-fast -extern mod inner_static; +extern crate inner_static; pub fn main() { let a = inner_static::A::<()>; diff --git a/src/test/run-pass/intrinsic-atomics-cc.rs b/src/test/run-pass/intrinsic-atomics-cc.rs index 9554ed20e0506..7fda83a14bb61 100644 --- a/src/test/run-pass/intrinsic-atomics-cc.rs +++ b/src/test/run-pass/intrinsic-atomics-cc.rs @@ -11,7 +11,7 @@ // ignore-fast - check-fast doesn't understand aux-build // aux-build:cci_intrinsic.rs -extern mod cci_intrinsic; +extern crate cci_intrinsic; use cci_intrinsic::atomic_xchg; pub fn main() { diff --git a/src/test/run-pass/intrinsics-integer.rs b/src/test/run-pass/intrinsics-integer.rs index 0a805ecc382b7..9c62f5052b2a6 100644 --- a/src/test/run-pass/intrinsics-integer.rs +++ b/src/test/run-pass/intrinsics-integer.rs @@ -12,7 +12,7 @@ #[feature(globs)]; -extern mod extra; +extern crate extra; mod rusti { extern "rust-intrinsic" { diff --git a/src/test/run-pass/invoke-external-foreign.rs b/src/test/run-pass/invoke-external-foreign.rs index d2fd1555228d8..def9a590a8358 100644 --- a/src/test/run-pass/invoke-external-foreign.rs +++ b/src/test/run-pass/invoke-external-foreign.rs @@ -16,7 +16,7 @@ // successfully (and safely) invoke external, cdecl // functions from outside the crate. -extern mod foreign_lib; +extern crate foreign_lib; pub fn main() { unsafe { diff --git a/src/test/run-pass/issue-10031.rs b/src/test/run-pass/issue-10031.rs index da1460085c0ac..bde8b194c40ab 100644 --- a/src/test/run-pass/issue-10031.rs +++ b/src/test/run-pass/issue-10031.rs @@ -10,7 +10,7 @@ // ignore-fast - check-fast doesn't understand aux-build // aux-build:issue_10031_aux.rs -extern mod issue_10031_aux; +extern crate issue_10031_aux; pub fn main() { let _ = issue_10031_aux::Wrap(()); diff --git a/src/test/run-pass/issue-11224.rs b/src/test/run-pass/issue-11224.rs index 74062be6d8267..23f1834fe8736 100644 --- a/src/test/run-pass/issue-11224.rs +++ b/src/test/run-pass/issue-11224.rs @@ -11,6 +11,6 @@ // aux-build:issue-11224.rs // ignore-fast -extern mod unused = "issue-11224"; +extern crate unused = "issue-11224"; pub fn main() {} diff --git a/src/test/run-pass/issue-11225-1.rs b/src/test/run-pass/issue-11225-1.rs index 212bbba944150..ea0e66151449a 100644 --- a/src/test/run-pass/issue-11225-1.rs +++ b/src/test/run-pass/issue-11225-1.rs @@ -11,7 +11,7 @@ // aux-build:issue-11225-1.rs // ignore-fast -extern mod foo = "issue-11225-1"; +extern crate foo = "issue-11225-1"; pub fn main() { foo::foo(1); diff --git a/src/test/run-pass/issue-11225-2.rs b/src/test/run-pass/issue-11225-2.rs index 2fe729067fbeb..95ed77eba049b 100644 --- a/src/test/run-pass/issue-11225-2.rs +++ b/src/test/run-pass/issue-11225-2.rs @@ -11,7 +11,7 @@ // aux-build:issue-11225-2.rs // ignore-fast -extern mod foo = "issue-11225-2"; +extern crate foo = "issue-11225-2"; pub fn main() { foo::foo(1); diff --git a/src/test/run-pass/issue-2316-c.rs b/src/test/run-pass/issue-2316-c.rs index cc859ff3be584..8dd64b1dbc9b3 100644 --- a/src/test/run-pass/issue-2316-c.rs +++ b/src/test/run-pass/issue-2316-c.rs @@ -12,7 +12,7 @@ // aux-build:issue_2316_a.rs // aux-build:issue_2316_b.rs -extern mod issue_2316_b; +extern crate issue_2316_b; use issue_2316_b::cloth; pub fn main() { diff --git a/src/test/run-pass/issue-2380-b.rs b/src/test/run-pass/issue-2380-b.rs index 3d36c1e2d58c7..f312a1b080a2e 100644 --- a/src/test/run-pass/issue-2380-b.rs +++ b/src/test/run-pass/issue-2380-b.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:issue-2380.rs -extern mod a; +extern crate a; pub fn main() { a::f::<()>(); diff --git a/src/test/run-pass/issue-2383.rs b/src/test/run-pass/issue-2383.rs index 2798d247c9d85..5b13be23f8ae1 100644 --- a/src/test/run-pass/issue-2383.rs +++ b/src/test/run-pass/issue-2383.rs @@ -10,7 +10,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod collections; +extern crate collections; use collections::RingBuf; use collections::Deque; diff --git a/src/test/run-pass/issue-2414-c.rs b/src/test/run-pass/issue-2414-c.rs index e51f6caa8d3e4..86cd1576bb01a 100644 --- a/src/test/run-pass/issue-2414-c.rs +++ b/src/test/run-pass/issue-2414-c.rs @@ -12,6 +12,6 @@ // aux-build:issue-2414-a.rs // aux-build:issue-2414-b.rs -extern mod b; +extern crate b; pub fn main() {} diff --git a/src/test/run-pass/issue-2472.rs b/src/test/run-pass/issue-2472.rs index 7d1b77d2db9aa..b025f80a888a3 100644 --- a/src/test/run-pass/issue-2472.rs +++ b/src/test/run-pass/issue-2472.rs @@ -11,7 +11,7 @@ // aux-build:issue_2472_b.rs // ignore-fast -extern mod issue_2472_b; +extern crate issue_2472_b; use issue_2472_b::{S, T}; diff --git a/src/test/run-pass/issue-2526-a.rs b/src/test/run-pass/issue-2526-a.rs index c58e214113c71..b10871f78d442 100644 --- a/src/test/run-pass/issue-2526-a.rs +++ b/src/test/run-pass/issue-2526-a.rs @@ -14,7 +14,7 @@ #[feature(globs)]; #[allow(unused_imports)]; -extern mod issue_2526; +extern crate issue_2526; use issue_2526::*; pub fn main() {} diff --git a/src/test/run-pass/issue-2631-b.rs b/src/test/run-pass/issue-2631-b.rs index 48976a9524021..68f2fd95cdefa 100644 --- a/src/test/run-pass/issue-2631-b.rs +++ b/src/test/run-pass/issue-2631-b.rs @@ -13,7 +13,7 @@ // ignore-fast // aux-build:issue-2631-a.rs -extern mod req; +extern crate req; use req::request; use std::cell::RefCell; diff --git a/src/test/run-pass/issue-2723-b.rs b/src/test/run-pass/issue-2723-b.rs index 142a5cb6500e8..ef20c481eb9c3 100644 --- a/src/test/run-pass/issue-2723-b.rs +++ b/src/test/run-pass/issue-2723-b.rs @@ -11,7 +11,7 @@ // ignore-fast: aux-build not compatible with fast // aux-build:issue_2723_a.rs -extern mod issue_2723_a; +extern crate issue_2723_a; use issue_2723_a::f; pub fn main() { diff --git a/src/test/run-pass/issue-2804.rs b/src/test/run-pass/issue-2804.rs index 1ac3c4b0fbc21..a9ac81be0ba49 100644 --- a/src/test/run-pass/issue-2804.rs +++ b/src/test/run-pass/issue-2804.rs @@ -10,7 +10,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use extra::json; use std::hashmap::HashMap; diff --git a/src/test/run-pass/issue-2904.rs b/src/test/run-pass/issue-2904.rs index 31a51c826c410..2816609ef97dc 100644 --- a/src/test/run-pass/issue-2904.rs +++ b/src/test/run-pass/issue-2904.rs @@ -14,7 +14,7 @@ /// Map representation -extern mod extra; +extern crate extra; use std::io; use std::to_str; diff --git a/src/test/run-pass/issue-2989.rs b/src/test/run-pass/issue-2989.rs index 9b667ab433b10..94e7297f17993 100644 --- a/src/test/run-pass/issue-2989.rs +++ b/src/test/run-pass/issue-2989.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use std::vec; diff --git a/src/test/run-pass/issue-3012-2.rs b/src/test/run-pass/issue-3012-2.rs index af45c88d22e6b..0ffbdc3c5b897 100644 --- a/src/test/run-pass/issue-3012-2.rs +++ b/src/test/run-pass/issue-3012-2.rs @@ -13,7 +13,7 @@ #[feature(managed_boxes)]; -extern mod socketlib; +extern crate socketlib; use socketlib::socket; use std::libc; diff --git a/src/test/run-pass/issue-3424.rs b/src/test/run-pass/issue-3424.rs index b790f73271707..374607326dfef 100644 --- a/src/test/run-pass/issue-3424.rs +++ b/src/test/run-pass/issue-3424.rs @@ -11,7 +11,7 @@ // except according to those terms. // rustc --test ignores2.rs && ./ignores2 -extern mod extra; +extern crate extra; use std::path::{Path}; use std::path; diff --git a/src/test/run-pass/issue-3556.rs b/src/test/run-pass/issue-3556.rs index 9e20de16ae1bb..e7089a6a21e5f 100644 --- a/src/test/run-pass/issue-3556.rs +++ b/src/test/run-pass/issue-3556.rs @@ -10,7 +10,7 @@ #[feature(managed_boxes)]; -extern mod extra; +extern crate extra; enum Token { Text(@~str), diff --git a/src/test/run-pass/issue-3563-3.rs b/src/test/run-pass/issue-3563-3.rs index f60d8b2de64a1..8e5dd762c630f 100644 --- a/src/test/run-pass/issue-3563-3.rs +++ b/src/test/run-pass/issue-3563-3.rs @@ -16,7 +16,7 @@ // However the extra library is designed to be optional (for code that must run on constrained // environments like embedded devices or special environments like kernel code) so it must // be explicitly linked in. -extern mod extra; +extern crate extra; // Extern mod controls linkage. Use controls the visibility of names to modules that are // already linked in. Using WriterUtil allows us to use the write_line method. diff --git a/src/test/run-pass/issue-3574.rs b/src/test/run-pass/issue-3574.rs index ace27c5ea11f6..b216ca9a1ca30 100644 --- a/src/test/run-pass/issue-3574.rs +++ b/src/test/run-pass/issue-3574.rs @@ -11,7 +11,7 @@ #[allow(unnecessary_allocation)]; // rustc --test match_borrowed_str.rs.rs && ./match_borrowed_str.rs -extern mod extra; +extern crate extra; fn compare(x: &str, y: &str) -> bool { diff --git a/src/test/run-pass/issue-3609.rs b/src/test/run-pass/issue-3609.rs index 9f6b1578b9575..fe9c5d5491fee 100644 --- a/src/test/run-pass/issue-3609.rs +++ b/src/test/run-pass/issue-3609.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use std::comm::Chan; use std::task; diff --git a/src/test/run-pass/issue-3979-xcrate.rs b/src/test/run-pass/issue-3979-xcrate.rs index deb0c8ebb7fca..a50287de97eab 100644 --- a/src/test/run-pass/issue-3979-xcrate.rs +++ b/src/test/run-pass/issue-3979-xcrate.rs @@ -10,7 +10,7 @@ // ignore-fast // aux-build:issue_3979_traits.rs -extern mod issue_3979_traits; +extern crate issue_3979_traits; use issue_3979_traits::{Positioned, Movable}; struct Point { x: int, y: int } diff --git a/src/test/run-pass/issue-4016.rs b/src/test/run-pass/issue-4016.rs index 7f9f48b742ad4..9c472e9c39aa2 100644 --- a/src/test/run-pass/issue-4016.rs +++ b/src/test/run-pass/issue-4016.rs @@ -11,8 +11,8 @@ // ignore-fast -extern mod extra; -extern mod serialize; +extern crate extra; +extern crate serialize; use extra::json; use serialize::Decodable; diff --git a/src/test/run-pass/issue-4036.rs b/src/test/run-pass/issue-4036.rs index 476aa8a07120f..3b9cabf664a43 100644 --- a/src/test/run-pass/issue-4036.rs +++ b/src/test/run-pass/issue-4036.rs @@ -13,8 +13,8 @@ // Issue #4036: Test for an issue that arose around fixing up type inference // byproducts in vtable records. -extern mod extra; -extern mod serialize; +extern crate extra; +extern crate serialize; use extra::json; use serialize::Decodable; diff --git a/src/test/run-pass/issue-4208.rs b/src/test/run-pass/issue-4208.rs index 3615e9cb83922..508b4dc0b5178 100644 --- a/src/test/run-pass/issue-4208.rs +++ b/src/test/run-pass/issue-4208.rs @@ -11,7 +11,7 @@ // aux-build:issue-4208-cc.rs // ignore-fast - check-fast hates cross-crate tests -extern mod numeric; +extern crate numeric; use numeric::{sin, Angle}; fn foo>(theta: A) -> T { sin(&theta) } diff --git a/src/test/run-pass/issue-4241.rs b/src/test/run-pass/issue-4241.rs index 085f2476c5d01..f6c29658e6a31 100644 --- a/src/test/run-pass/issue-4241.rs +++ b/src/test/run-pass/issue-4241.rs @@ -11,7 +11,7 @@ // ignore-fast // ignore-test needs networking -extern mod extra; +extern crate extra; use extra::net::tcp::TcpSocketBuf; diff --git a/src/test/run-pass/issue-4545.rs b/src/test/run-pass/issue-4545.rs index 6a5f0772fcf85..9781f4aba7e65 100644 --- a/src/test/run-pass/issue-4545.rs +++ b/src/test/run-pass/issue-4545.rs @@ -11,5 +11,5 @@ // ignore-fast check-fast doesn't like aux-build // aux-build:issue-4545.rs -extern mod somelib = "issue-4545"; +extern crate somelib = "issue-4545"; pub fn main() { somelib::mk::(); } diff --git a/src/test/run-pass/issue-5521.rs b/src/test/run-pass/issue-5521.rs index 953956337b644..ca62b7bb8952b 100644 --- a/src/test/run-pass/issue-5521.rs +++ b/src/test/run-pass/issue-5521.rs @@ -13,7 +13,7 @@ #[feature(managed_boxes)]; -extern mod foo = "issue-5521"; +extern crate foo = "issue-5521"; fn foo(a: foo::map) { if false { diff --git a/src/test/run-pass/issue-6919.rs b/src/test/run-pass/issue-6919.rs index 5e56a45622efa..6d84268fb418d 100644 --- a/src/test/run-pass/issue-6919.rs +++ b/src/test/run-pass/issue-6919.rs @@ -12,7 +12,7 @@ // ignore-fast #[crate_id="issue-6919"]; -extern mod issue6919_3; +extern crate issue6919_3; pub fn main() { issue6919_3::D.k; diff --git a/src/test/run-pass/issue-7178.rs b/src/test/run-pass/issue-7178.rs index 7c44e57814429..a20ab1ca9e449 100644 --- a/src/test/run-pass/issue-7178.rs +++ b/src/test/run-pass/issue-7178.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:issue-7178.rs -extern mod cross_crate_self = "issue-7178"; +extern crate cross_crate_self = "issue-7178"; pub fn main() { let _ = cross_crate_self::Foo::new(&1i); diff --git a/src/test/run-pass/issue-8044.rs b/src/test/run-pass/issue-8044.rs index 3f3f1d7e1d71c..450c83515162d 100644 --- a/src/test/run-pass/issue-8044.rs +++ b/src/test/run-pass/issue-8044.rs @@ -11,7 +11,7 @@ // ignore-fast check-fast doesn't like aux-build // aux-build:issue-8044.rs -extern mod minimal = "issue-8044"; +extern crate minimal = "issue-8044"; use minimal::{BTree, leaf}; pub fn main() { diff --git a/src/test/run-pass/issue-8259.rs b/src/test/run-pass/issue-8259.rs index 765852654f9a2..715c25feff3f3 100644 --- a/src/test/run-pass/issue-8259.rs +++ b/src/test/run-pass/issue-8259.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:issue-8259.rs -extern mod other = "issue-8259"; +extern crate other = "issue-8259"; static a: other::Foo<'static> = other::A; pub fn main() {} diff --git a/src/test/run-pass/issue-8401.rs b/src/test/run-pass/issue-8401.rs index e750066199adf..e47d3b8edce90 100644 --- a/src/test/run-pass/issue-8401.rs +++ b/src/test/run-pass/issue-8401.rs @@ -11,6 +11,6 @@ // aux-build:issue_8401.rs // ignore-fast -extern mod issue_8401; +extern crate issue_8401; pub fn main() {} diff --git a/src/test/run-pass/issue-8860.rs b/src/test/run-pass/issue-8860.rs index 230dce1615158..d22de5ce4c80a 100644 --- a/src/test/run-pass/issue-8860.rs +++ b/src/test/run-pass/issue-8860.rs @@ -10,7 +10,7 @@ // ignore-fast -extern mod green; +extern crate green; static mut DROP: int = 0i; static mut DROP_S: int = 0i; diff --git a/src/test/run-pass/issue-9123.rs b/src/test/run-pass/issue-9123.rs index b5aef4b73ac1d..ea9d7edecd1cd 100644 --- a/src/test/run-pass/issue-9123.rs +++ b/src/test/run-pass/issue-9123.rs @@ -11,6 +11,6 @@ // ignore-fast check-fast doesn't like aux-build // aux-build:issue_9123.rs -extern mod issue_9123; +extern crate issue_9123; pub fn main() {} diff --git a/src/test/run-pass/issue-9188.rs b/src/test/run-pass/issue-9188.rs index 8f5978d356ee3..8cded636338c9 100644 --- a/src/test/run-pass/issue-9188.rs +++ b/src/test/run-pass/issue-9188.rs @@ -11,7 +11,7 @@ // aux-build:issue_9188.rs // ignore-fast check-fast doesn't like aux-build -extern mod issue_9188; +extern crate issue_9188; pub fn main() { let a = issue_9188::bar(); diff --git a/src/test/run-pass/issue-9906.rs b/src/test/run-pass/issue-9906.rs index ea1958a14bb79..c32cab9638cc1 100644 --- a/src/test/run-pass/issue-9906.rs +++ b/src/test/run-pass/issue-9906.rs @@ -8,10 +8,10 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -// ignore-fast check-fast doesn't like extern mod +// ignore-fast check-fast doesn't like extern crate // aux-build:issue-9906.rs -extern mod testmod = "issue-9906"; +extern crate testmod = "issue-9906"; pub fn main() { testmod::foo(); diff --git a/src/test/run-pass/issue-9968.rs b/src/test/run-pass/issue-9968.rs index c076979060c90..468fcdca6bd03 100644 --- a/src/test/run-pass/issue-9968.rs +++ b/src/test/run-pass/issue-9968.rs @@ -8,10 +8,10 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -// ignore-fast check-fast doesn't like extern mod +// ignore-fast check-fast doesn't like extern crate // aux-build:issue-9968.rs -extern mod lib = "issue-9968"; +extern crate lib = "issue-9968"; use lib::{Trait, Struct}; diff --git a/src/test/run-pass/issue2170exe.rs b/src/test/run-pass/issue2170exe.rs index c4d76808013d9..481b6a2723b73 100644 --- a/src/test/run-pass/issue2170exe.rs +++ b/src/test/run-pass/issue2170exe.rs @@ -10,7 +10,7 @@ // ignore-fast - check-fail fast doesn't under aux-build // aux-build:issue2170lib.rs -extern mod issue2170lib; +extern crate issue2170lib; pub fn main() { // let _ = issue2170lib::rsrc(2i32); diff --git a/src/test/run-pass/issue2378c.rs b/src/test/run-pass/issue2378c.rs index 27098d471d1c3..17733361de421 100644 --- a/src/test/run-pass/issue2378c.rs +++ b/src/test/run-pass/issue2378c.rs @@ -12,8 +12,8 @@ // aux-build:issue2378b.rs // ignore-fast - check-fast doesn't understand aux-build -extern mod issue2378a; -extern mod issue2378b; +extern crate issue2378a; +extern crate issue2378b; use issue2378a::{just}; use issue2378b::{two_maybes}; diff --git a/src/test/run-pass/issue_3136_b.rs b/src/test/run-pass/issue_3136_b.rs index 86b4624c34ece..4144e0c85c853 100644 --- a/src/test/run-pass/issue_3136_b.rs +++ b/src/test/run-pass/issue_3136_b.rs @@ -11,5 +11,5 @@ // ignore-fast - check-fast doesn't understand aux-build // aux-build:issue_3136_a.rc -extern mod issue_3136_a; +extern crate issue_3136_a; pub fn main() {} diff --git a/src/test/run-pass/issue_9155.rs b/src/test/run-pass/issue_9155.rs index 48ee1fe70d097..09a6693eb4c5a 100644 --- a/src/test/run-pass/issue_9155.rs +++ b/src/test/run-pass/issue_9155.rs @@ -11,7 +11,7 @@ // aux-build:issue_9155.rs // ignore-fast check-fast doesn't like the aux-build -extern mod issue_9155; +extern crate issue_9155; struct Baz; diff --git a/src/test/run-pass/item-attributes.rs b/src/test/run-pass/item-attributes.rs index 133660e28d2ac..8ea06e510803d 100644 --- a/src/test/run-pass/item-attributes.rs +++ b/src/test/run-pass/item-attributes.rs @@ -140,7 +140,7 @@ mod test_attr_inner_then_outer_multi { } mod test_distinguish_syntax_ext { - extern mod extra; + extern crate extra; pub fn f() { format!("test{}", "s"); diff --git a/src/test/run-pass/kinds-in-metadata.rs b/src/test/run-pass/kinds-in-metadata.rs index f9165ce309f67..7799bd7016217 100644 --- a/src/test/run-pass/kinds-in-metadata.rs +++ b/src/test/run-pass/kinds-in-metadata.rs @@ -16,7 +16,7 @@ // Tests that metadata serialization works for the `Pod` kind. -extern mod kinds_in_metadata; +extern crate kinds_in_metadata; use kinds_in_metadata::f; diff --git a/src/test/run-pass/linkage-visibility.rs b/src/test/run-pass/linkage-visibility.rs index 9ac2b710995d6..e4c0d023298d0 100644 --- a/src/test/run-pass/linkage-visibility.rs +++ b/src/test/run-pass/linkage-visibility.rs @@ -9,11 +9,11 @@ // except according to those terms. // aux-build:linkage-visibility.rs -// ignore-fast check-fast doesn't like 'extern mod' +// ignore-fast check-fast doesn't like 'extern crate' // ignore-android: FIXME(#10379) // ignore-win32: std::unstable::dynamic_lib does not work on win32 well -extern mod foo = "linkage-visibility"; +extern crate foo = "linkage-visibility"; pub fn main() { foo::test(); diff --git a/src/test/run-pass/log-knows-the-names-of-variants-in-std.rs b/src/test/run-pass/log-knows-the-names-of-variants-in-std.rs index 24eb48e92cd0e..05c5a7a67f563 100644 --- a/src/test/run-pass/log-knows-the-names-of-variants-in-std.rs +++ b/src/test/run-pass/log-knows-the-names-of-variants-in-std.rs @@ -10,7 +10,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod collections; +extern crate collections; use collections::list; #[deriving(Clone)] diff --git a/src/test/run-pass/logging-right-crate.rs b/src/test/run-pass/logging-right-crate.rs index f140a73a776b1..68afcc98bba8b 100644 --- a/src/test/run-pass/logging-right-crate.rs +++ b/src/test/run-pass/logging-right-crate.rs @@ -22,7 +22,7 @@ // longer happens by enabling logging for *this* crate and then invoking a // function in an external crate which will fail when logging is enabled. -extern mod logging_right_crate; +extern crate logging_right_crate; pub fn main() { // this function fails if logging is turned on diff --git a/src/test/run-pass/lots-a-fail.rs b/src/test/run-pass/lots-a-fail.rs index e4886ba115c94..9c33ff59dacdc 100644 --- a/src/test/run-pass/lots-a-fail.rs +++ b/src/test/run-pass/lots-a-fail.rs @@ -10,7 +10,7 @@ // ignore-test linked failure -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/macro-crate-def-only.rs b/src/test/run-pass/macro-crate-def-only.rs index 08529bb2d009e..2c2ffd50eae9b 100644 --- a/src/test/run-pass/macro-crate-def-only.rs +++ b/src/test/run-pass/macro-crate-def-only.rs @@ -14,7 +14,7 @@ #[feature(phase)]; #[phase(syntax)] -extern mod macro_crate_def_only; +extern crate macro_crate_def_only; pub fn main() { assert_eq!(5, make_a_5!()); diff --git a/src/test/run-pass/macro-export-inner-module.rs b/src/test/run-pass/macro-export-inner-module.rs index e31a78e604f87..14c6423ce40cc 100644 --- a/src/test/run-pass/macro-export-inner-module.rs +++ b/src/test/run-pass/macro-export-inner-module.rs @@ -15,7 +15,7 @@ #[feature(phase)]; #[phase(syntax)] -extern mod macro_export_inner_module; +extern crate macro_export_inner_module; pub fn main() { assert_eq!(1, foo!()); diff --git a/src/test/run-pass/match-join.rs b/src/test/run-pass/match-join.rs index 0f01985f274ad..90768fdc6c903 100644 --- a/src/test/run-pass/match-join.rs +++ b/src/test/run-pass/match-join.rs @@ -9,7 +9,7 @@ // except according to those terms. -extern mod extra; +extern crate extra; fn foo(y: Option) { let mut x: int; diff --git a/src/test/run-pass/monomorphized-callees-with-ty-params-3314.rs b/src/test/run-pass/monomorphized-callees-with-ty-params-3314.rs index 5e03b47d1b1dc..3bedd340fea25 100644 --- a/src/test/run-pass/monomorphized-callees-with-ty-params-3314.rs +++ b/src/test/run-pass/monomorphized-callees-with-ty-params-3314.rs @@ -10,7 +10,7 @@ #[feature(managed_boxes)]; -extern mod extra; +extern crate extra; trait Serializer { } diff --git a/src/test/run-pass/morestack5.rs b/src/test/run-pass/morestack5.rs index c04199dad3e12..ba1128978d38b 100644 --- a/src/test/run-pass/morestack5.rs +++ b/src/test/run-pass/morestack5.rs @@ -12,7 +12,7 @@ // This test will call __morestack with various minimum stack sizes -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/move-3-unique.rs b/src/test/run-pass/move-3-unique.rs index 46308e02e7858..2bd1eb7fd4bff 100644 --- a/src/test/run-pass/move-3-unique.rs +++ b/src/test/run-pass/move-3-unique.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; #[deriving(Clone)] struct Triple { diff --git a/src/test/run-pass/move-3.rs b/src/test/run-pass/move-3.rs index e915cf6aed798..2819d9bd76e40 100644 --- a/src/test/run-pass/move-3.rs +++ b/src/test/run-pass/move-3.rs @@ -10,7 +10,7 @@ #[feature(managed_boxes)]; -extern mod extra; +extern crate extra; struct Triple { x: int, y: int, z: int } diff --git a/src/test/run-pass/move-4-unique.rs b/src/test/run-pass/move-4-unique.rs index 48621cf03be6a..660fb447bb0e5 100644 --- a/src/test/run-pass/move-4-unique.rs +++ b/src/test/run-pass/move-4-unique.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; struct Triple {a: int, b: int, c: int} diff --git a/src/test/run-pass/move-4.rs b/src/test/run-pass/move-4.rs index ec66e72ac6979..67b071af0a27e 100644 --- a/src/test/run-pass/move-4.rs +++ b/src/test/run-pass/move-4.rs @@ -10,7 +10,7 @@ #[feature(managed_boxes)]; -extern mod extra; +extern crate extra; struct Triple { a: int, b: int, c: int } diff --git a/src/test/run-pass/moves-based-on-type-cross-crate.rs b/src/test/run-pass/moves-based-on-type-cross-crate.rs index b3ea2b365634c..abccd11d8b981 100644 --- a/src/test/run-pass/moves-based-on-type-cross-crate.rs +++ b/src/test/run-pass/moves-based-on-type-cross-crate.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:moves_based_on_type_lib.rs -extern mod moves_based_on_type_lib; +extern crate moves_based_on_type_lib; use moves_based_on_type_lib::f; pub fn main() { diff --git a/src/test/run-pass/mutable-alias-vec.rs b/src/test/run-pass/mutable-alias-vec.rs index 9779db91a9c8a..f512a4659853a 100644 --- a/src/test/run-pass/mutable-alias-vec.rs +++ b/src/test/run-pass/mutable-alias-vec.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; fn grow(v: &mut ~[int]) { v.push(1); diff --git a/src/test/run-pass/native-always-waits.rs b/src/test/run-pass/native-always-waits.rs index 319b2be52e5bc..18a64c8bd5be8 100644 --- a/src/test/run-pass/native-always-waits.rs +++ b/src/test/run-pass/native-always-waits.rs @@ -11,7 +11,7 @@ // ignore-fast // ignore-android (FIXME #11419) -extern mod native; +extern crate native; static mut set: bool = false; diff --git a/src/test/run-pass/nested_item_main.rs b/src/test/run-pass/nested_item_main.rs index 121847ef3cb28..5fe1cd7fa558a 100644 --- a/src/test/run-pass/nested_item_main.rs +++ b/src/test/run-pass/nested_item_main.rs @@ -11,7 +11,7 @@ // aux-build:nested_item.rs // ignore-fast -extern mod nested_item; +extern crate nested_item; pub fn main() { assert_eq!(2, nested_item::foo::<()>()); diff --git a/src/test/run-pass/newtype-struct-xc-2.rs b/src/test/run-pass/newtype-struct-xc-2.rs index 812bf4d600bcb..9aec3f2c4f7e7 100644 --- a/src/test/run-pass/newtype-struct-xc-2.rs +++ b/src/test/run-pass/newtype-struct-xc-2.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:newtype_struct_xc.rs -extern mod newtype_struct_xc; +extern crate newtype_struct_xc; use newtype_struct_xc::Au; fn f() -> Au { diff --git a/src/test/run-pass/newtype-struct-xc.rs b/src/test/run-pass/newtype-struct-xc.rs index 6f5da821a108b..98a55f2975825 100644 --- a/src/test/run-pass/newtype-struct-xc.rs +++ b/src/test/run-pass/newtype-struct-xc.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:newtype_struct_xc.rs -extern mod newtype_struct_xc; +extern crate newtype_struct_xc; pub fn main() { let _ = newtype_struct_xc::Au(2); diff --git a/src/test/run-pass/no-std-xcrate.rs b/src/test/run-pass/no-std-xcrate.rs index f5394481172a8..f149b8645d4cd 100644 --- a/src/test/run-pass/no-std-xcrate.rs +++ b/src/test/run-pass/no-std-xcrate.rs @@ -14,7 +14,7 @@ // This tests that crates which link to std can also be linked to crates with // #[no_std] that have no lang items. -extern mod no_std_crate; +extern crate no_std_crate; pub fn main() { no_std_crate::foo(); diff --git a/src/test/run-pass/no-std-xcrate2.rs b/src/test/run-pass/no-std-xcrate2.rs index a22814af23e67..7e734a7d9e262 100644 --- a/src/test/run-pass/no-std-xcrate2.rs +++ b/src/test/run-pass/no-std-xcrate2.rs @@ -18,7 +18,7 @@ #[no_std]; -extern mod no_std_crate; +extern crate no_std_crate; // This is an unfortunate thing to have to do on linux :( #[cfg(target_os = "linux")] diff --git a/src/test/run-pass/non-boolean-pure-fns.rs b/src/test/run-pass/non-boolean-pure-fns.rs index 60b018fde7ab6..cb08c81d9e0ed 100644 --- a/src/test/run-pass/non-boolean-pure-fns.rs +++ b/src/test/run-pass/non-boolean-pure-fns.rs @@ -12,7 +12,7 @@ #[feature(managed_boxes)]; -extern mod collections; +extern crate collections; use collections::list::{List, Cons, Nil, head, is_empty}; diff --git a/src/test/run-pass/once-move-out-on-heap.rs b/src/test/run-pass/once-move-out-on-heap.rs index 7f0b22ed1d0ab..5067a6c4f926f 100644 --- a/src/test/run-pass/once-move-out-on-heap.rs +++ b/src/test/run-pass/once-move-out-on-heap.rs @@ -13,7 +13,7 @@ // ignore-fast #[feature(once_fns)]; -extern mod sync; +extern crate sync; use sync::Arc; fn foo(blk: proc()) { diff --git a/src/test/run-pass/once-move-out-on-stack.rs b/src/test/run-pass/once-move-out-on-stack.rs index 4d344a9b7b6ff..ffee1e400afff 100644 --- a/src/test/run-pass/once-move-out-on-stack.rs +++ b/src/test/run-pass/once-move-out-on-stack.rs @@ -13,7 +13,7 @@ // ignore-fast #[feature(once_fns)]; -extern mod sync; +extern crate sync; use sync::Arc; fn foo(blk: once ||) { diff --git a/src/test/run-pass/packed-struct-size-xc.rs b/src/test/run-pass/packed-struct-size-xc.rs index 13142c7bff87b..2ee90eb2c4c6b 100644 --- a/src/test/run-pass/packed-struct-size-xc.rs +++ b/src/test/run-pass/packed-struct-size-xc.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:packed.rs -extern mod packed; +extern crate packed; use std::mem; diff --git a/src/test/run-pass/phase-syntax-link-does-resolve.rs b/src/test/run-pass/phase-syntax-link-does-resolve.rs index a829dd3fbc540..a7b8297487d00 100644 --- a/src/test/run-pass/phase-syntax-link-does-resolve.rs +++ b/src/test/run-pass/phase-syntax-link-does-resolve.rs @@ -27,7 +27,7 @@ #[feature(phase)]; #[phase(syntax, link)] -extern mod macro_crate_test; +extern crate macro_crate_test; fn main() { assert_eq!(1, make_a_1!()); diff --git a/src/test/run-pass/placement-new-arena.rs b/src/test/run-pass/placement-new-arena.rs index eed01b6d00a87..876d9d2a6908d 100644 --- a/src/test/run-pass/placement-new-arena.rs +++ b/src/test/run-pass/placement-new-arena.rs @@ -10,7 +10,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod arena; +extern crate arena; use arena::Arena; pub fn main() { diff --git a/src/test/run-pass/preempt.rs b/src/test/run-pass/preempt.rs index 23a6104af7dc0..5f8da9ddaffca 100644 --- a/src/test/run-pass/preempt.rs +++ b/src/test/run-pass/preempt.rs @@ -12,7 +12,7 @@ // This checks that preemption works. // note: halfway done porting to modern rust -extern mod extra; +extern crate extra; use std::comm; use extra::comm; diff --git a/src/test/run-pass/priv-impl-prim-ty.rs b/src/test/run-pass/priv-impl-prim-ty.rs index 46a520ae21ce3..4c7160a8eee03 100644 --- a/src/test/run-pass/priv-impl-prim-ty.rs +++ b/src/test/run-pass/priv-impl-prim-ty.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:priv-impl-prim-ty.rs -extern mod bar = "priv-impl-prim-ty"; +extern crate bar = "priv-impl-prim-ty"; pub fn main() { bar::frob(1i); diff --git a/src/test/run-pass/privacy-reexport.rs b/src/test/run-pass/privacy-reexport.rs index a2845d020b284..e9450d1e77dc0 100644 --- a/src/test/run-pass/privacy-reexport.rs +++ b/src/test/run-pass/privacy-reexport.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:privacy_reexport.rs -extern mod privacy_reexport; +extern crate privacy_reexport; pub fn main() { privacy_reexport::bar::frob(); diff --git a/src/test/run-pass/pub-use-xcrate.rs b/src/test/run-pass/pub-use-xcrate.rs index 0a25840c3936e..2d4f5f743b8b9 100644 --- a/src/test/run-pass/pub-use-xcrate.rs +++ b/src/test/run-pass/pub-use-xcrate.rs @@ -12,7 +12,7 @@ // aux-build:pub_use_xcrate1.rs // aux-build:pub_use_xcrate2.rs -extern mod pub_use_xcrate2; +extern crate pub_use_xcrate2; use pub_use_xcrate2::Foo; diff --git a/src/test/run-pass/pub_use_mods_xcrate_exe.rs b/src/test/run-pass/pub_use_mods_xcrate_exe.rs index 3672d05f87adc..87185e39aa996 100644 --- a/src/test/run-pass/pub_use_mods_xcrate_exe.rs +++ b/src/test/run-pass/pub_use_mods_xcrate_exe.rs @@ -13,7 +13,7 @@ #[allow(unused_imports)]; -extern mod pub_use_mods_xcrate; +extern crate pub_use_mods_xcrate; use pub_use_mods_xcrate::a::c; pub fn main(){} diff --git a/src/test/run-pass/reexport-should-still-link.rs b/src/test/run-pass/reexport-should-still-link.rs index c5f27ab5e5b12..0c22fcb44e9c3 100644 --- a/src/test/run-pass/reexport-should-still-link.rs +++ b/src/test/run-pass/reexport-should-still-link.rs @@ -9,9 +9,9 @@ // except according to those terms. // aux-build:reexport-should-still-link.rs -// ignore-fast check-fast doesn't like extern mod +// ignore-fast check-fast doesn't like extern crate -extern mod foo = "reexport-should-still-link"; +extern crate foo = "reexport-should-still-link"; pub fn main() { foo::bar(); diff --git a/src/test/run-pass/reexported-static-methods-cross-crate.rs b/src/test/run-pass/reexported-static-methods-cross-crate.rs index 330776ca0467e..b3a7cf7442865 100644 --- a/src/test/run-pass/reexported-static-methods-cross-crate.rs +++ b/src/test/run-pass/reexported-static-methods-cross-crate.rs @@ -10,7 +10,7 @@ // ignore-fast // aux-build:reexported_static_methods.rs -extern mod reexported_static_methods; +extern crate reexported_static_methods; use reexported_static_methods::Foo; use reexported_static_methods::Baz; diff --git a/src/test/run-pass/regions-lifetime-static-items-enclosing-scopes.rs b/src/test/run-pass/regions-lifetime-static-items-enclosing-scopes.rs index e20717553c4c4..975dcab190251 100644 --- a/src/test/run-pass/regions-lifetime-static-items-enclosing-scopes.rs +++ b/src/test/run-pass/regions-lifetime-static-items-enclosing-scopes.rs @@ -11,7 +11,7 @@ // This test verifies that temporary lifetime is correctly computed // for static objects in enclosing scopes. -extern mod extra; +extern crate extra; use std::cmp::Eq; fn f(o: &mut Option) { diff --git a/src/test/run-pass/regions-mock-tcx.rs b/src/test/run-pass/regions-mock-tcx.rs index 43a8b452537bf..738a4899f2730 100644 --- a/src/test/run-pass/regions-mock-tcx.rs +++ b/src/test/run-pass/regions-mock-tcx.rs @@ -16,7 +16,7 @@ // - Multiple lifetime parameters // - Arenas -extern mod arena; +extern crate arena; use arena::Arena; use std::hashmap::HashMap; diff --git a/src/test/run-pass/rename-directory.rs b/src/test/run-pass/rename-directory.rs index 83f77baf56861..3f14d7befac27 100644 --- a/src/test/run-pass/rename-directory.rs +++ b/src/test/run-pass/rename-directory.rs @@ -12,7 +12,7 @@ // because it needs TempDir, which is in extra // ignore-fast -extern mod extra; +extern crate extra; use extra::tempfile::TempDir; use std::os; diff --git a/src/test/run-pass/send-iloop.rs b/src/test/run-pass/send-iloop.rs index 11f9252f22f5a..5116dcb8dc8eb 100644 --- a/src/test/run-pass/send-iloop.rs +++ b/src/test/run-pass/send-iloop.rs @@ -9,7 +9,7 @@ // except according to those terms. // ignore-test linked failure -extern mod extra; +extern crate extra; use std::comm; use std::task; diff --git a/src/test/run-pass/send_str_treemap.rs b/src/test/run-pass/send_str_treemap.rs index 1b7d7bf0b4b57..1543d34ae88b9 100644 --- a/src/test/run-pass/send_str_treemap.rs +++ b/src/test/run-pass/send_str_treemap.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod collections; +extern crate collections; use std::clone::{Clone, DeepClone}; use std::cmp::{TotalEq, Ord, TotalOrd, Equiv}; diff --git a/src/test/run-pass/spawn.rs b/src/test/run-pass/spawn.rs index d95f032e81438..002736693788a 100644 --- a/src/test/run-pass/spawn.rs +++ b/src/test/run-pass/spawn.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/stat.rs b/src/test/run-pass/stat.rs index c3e87d27ef210..33f4c9d9a982a 100644 --- a/src/test/run-pass/stat.rs +++ b/src/test/run-pass/stat.rs @@ -10,7 +10,7 @@ // ignore-fast -extern mod extra; +extern crate extra; use extra::tempfile; use std::io::File; diff --git a/src/test/run-pass/static-fn-inline-xc.rs b/src/test/run-pass/static-fn-inline-xc.rs index a6b1c649ddfcf..f679de04ba29e 100644 --- a/src/test/run-pass/static-fn-inline-xc.rs +++ b/src/test/run-pass/static-fn-inline-xc.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:static_fn_inline_xc_aux.rs -extern mod mycore = "static_fn_inline_xc_aux"; +extern crate mycore = "static_fn_inline_xc_aux"; use mycore::num; diff --git a/src/test/run-pass/static-fn-trait-xc.rs b/src/test/run-pass/static-fn-trait-xc.rs index 6c0a6461057f9..5643429d8e38b 100644 --- a/src/test/run-pass/static-fn-trait-xc.rs +++ b/src/test/run-pass/static-fn-trait-xc.rs @@ -11,7 +11,7 @@ // aux-build:static_fn_trait_xc_aux.rs // ignore-fast -extern mod mycore = "static_fn_trait_xc_aux"; +extern crate mycore = "static_fn_trait_xc_aux"; use mycore::num; diff --git a/src/test/run-pass/static-function-pointer-xc.rs b/src/test/run-pass/static-function-pointer-xc.rs index 22a7c0aa3919e..8471b63379223 100644 --- a/src/test/run-pass/static-function-pointer-xc.rs +++ b/src/test/run-pass/static-function-pointer-xc.rs @@ -10,7 +10,7 @@ // ignore-fast // aux-build:static-function-pointer-aux.rs -extern mod aux = "static-function-pointer-aux"; +extern crate aux = "static-function-pointer-aux"; fn f(x: int) -> int { x } diff --git a/src/test/run-pass/static-method-xcrate.rs b/src/test/run-pass/static-method-xcrate.rs index 343155cc99fa3..db3f61567d8b8 100644 --- a/src/test/run-pass/static-method-xcrate.rs +++ b/src/test/run-pass/static-method-xcrate.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:static-methods-crate.rs -extern mod static_methods_crate; +extern crate static_methods_crate; use static_methods_crate::read; diff --git a/src/test/run-pass/static-mut-xc.rs b/src/test/run-pass/static-mut-xc.rs index 9228434735af3..c7b17d91a8fc6 100644 --- a/src/test/run-pass/static-mut-xc.rs +++ b/src/test/run-pass/static-mut-xc.rs @@ -15,7 +15,7 @@ // ignore-fast // aux-build:static_mut_xc.rs -extern mod static_mut_xc; +extern crate static_mut_xc; unsafe fn static_bound(_: &'static int) {} diff --git a/src/test/run-pass/str-append.rs b/src/test/run-pass/str-append.rs index bede746f5690b..c6ff57ac4e804 100644 --- a/src/test/run-pass/str-append.rs +++ b/src/test/run-pass/str-append.rs @@ -10,7 +10,7 @@ -extern mod extra; +extern crate extra; fn test1() { let mut s: ~str = ~"hello"; diff --git a/src/test/run-pass/str-multiline.rs b/src/test/run-pass/str-multiline.rs index 59736829a231f..3c5a860d6c832 100644 --- a/src/test/run-pass/str-multiline.rs +++ b/src/test/run-pass/str-multiline.rs @@ -10,7 +10,7 @@ -extern mod extra; +extern crate extra; pub fn main() { let a: ~str = ~"this \ diff --git a/src/test/run-pass/string-self-append.rs b/src/test/run-pass/string-self-append.rs index 68f1e21571c31..34a818879d0b6 100644 --- a/src/test/run-pass/string-self-append.rs +++ b/src/test/run-pass/string-self-append.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; pub fn main() { // Make sure we properly handle repeated self-appends. diff --git a/src/test/run-pass/struct-destructuring-cross-crate.rs b/src/test/run-pass/struct-destructuring-cross-crate.rs index f7db1ae37b892..31ba7149c29b4 100644 --- a/src/test/run-pass/struct-destructuring-cross-crate.rs +++ b/src/test/run-pass/struct-destructuring-cross-crate.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:struct_destructuring_cross_crate.rs -extern mod struct_destructuring_cross_crate; +extern crate struct_destructuring_cross_crate; pub fn main() { let x = struct_destructuring_cross_crate::S { x: 1, y: 2 }; diff --git a/src/test/run-pass/struct_variant_xc.rs b/src/test/run-pass/struct_variant_xc.rs index bb3d07581bc6e..c9cd64161b7e7 100644 --- a/src/test/run-pass/struct_variant_xc.rs +++ b/src/test/run-pass/struct_variant_xc.rs @@ -10,7 +10,7 @@ // ignore-fast - check-fast doesn't understand aux-build // aux-build:struct_variant_xc_aux.rs -extern mod struct_variant_xc_aux; +extern crate struct_variant_xc_aux; use struct_variant_xc_aux::Variant; diff --git a/src/test/run-pass/task-comm-0.rs b/src/test/run-pass/task-comm-0.rs index ee88670ca14f8..f02e3a17813f9 100644 --- a/src/test/run-pass/task-comm-0.rs +++ b/src/test/run-pass/task-comm-0.rs @@ -10,7 +10,7 @@ // ignore-fast -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/task-comm-10.rs b/src/test/run-pass/task-comm-10.rs index 8e7250f6ab4a4..1c64cf9cff5c6 100644 --- a/src/test/run-pass/task-comm-10.rs +++ b/src/test/run-pass/task-comm-10.rs @@ -10,7 +10,7 @@ // ignore-fast -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/task-comm-11.rs b/src/test/run-pass/task-comm-11.rs index 4392419d26da4..3d6e841d31873 100644 --- a/src/test/run-pass/task-comm-11.rs +++ b/src/test/run-pass/task-comm-11.rs @@ -10,7 +10,7 @@ // ignore-fast -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/task-comm-12.rs b/src/test/run-pass/task-comm-12.rs index f6f6f3ba240cf..8092fb6d4ad2d 100644 --- a/src/test/run-pass/task-comm-12.rs +++ b/src/test/run-pass/task-comm-12.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/task-comm-13.rs b/src/test/run-pass/task-comm-13.rs index 53386c2f84540..6f22eb97c5113 100644 --- a/src/test/run-pass/task-comm-13.rs +++ b/src/test/run-pass/task-comm-13.rs @@ -10,7 +10,7 @@ // ignore-fast -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/task-comm-15.rs b/src/test/run-pass/task-comm-15.rs index b1cde6b93578c..4e4d38b9605ad 100644 --- a/src/test/run-pass/task-comm-15.rs +++ b/src/test/run-pass/task-comm-15.rs @@ -10,7 +10,7 @@ // ignore-fast -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/task-comm-17.rs b/src/test/run-pass/task-comm-17.rs index 4f9285d30b9e0..70a59c5b85dc4 100644 --- a/src/test/run-pass/task-comm-17.rs +++ b/src/test/run-pass/task-comm-17.rs @@ -12,7 +12,7 @@ // This test is specifically about spawning temporary closures. -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/task-comm-3.rs b/src/test/run-pass/task-comm-3.rs index f5374e7df05a9..732d72c11fec2 100644 --- a/src/test/run-pass/task-comm-3.rs +++ b/src/test/run-pass/task-comm-3.rs @@ -10,7 +10,7 @@ // ignore-fast -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/task-comm-5.rs b/src/test/run-pass/task-comm-5.rs index c63bf12db2b33..64ccf4f3df873 100644 --- a/src/test/run-pass/task-comm-5.rs +++ b/src/test/run-pass/task-comm-5.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; pub fn main() { test00(); } diff --git a/src/test/run-pass/task-comm-7.rs b/src/test/run-pass/task-comm-7.rs index ff43a80adaca1..e72e5677776d0 100644 --- a/src/test/run-pass/task-comm-7.rs +++ b/src/test/run-pass/task-comm-7.rs @@ -12,7 +12,7 @@ #[allow(dead_assignment)]; -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/task-comm-9.rs b/src/test/run-pass/task-comm-9.rs index d275aec5894ff..4a053b0c47a3a 100644 --- a/src/test/run-pass/task-comm-9.rs +++ b/src/test/run-pass/task-comm-9.rs @@ -10,7 +10,7 @@ // ignore-fast -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/task-comm-chan-nil.rs b/src/test/run-pass/task-comm-chan-nil.rs index 3277400704910..f5fe5be0d7613 100644 --- a/src/test/run-pass/task-comm-chan-nil.rs +++ b/src/test/run-pass/task-comm-chan-nil.rs @@ -9,7 +9,7 @@ // except according to those terms. -extern mod extra; +extern crate extra; // rustboot can't transmit nils across channels because they don't have // any size, but rustc currently can because they do have size. Whether diff --git a/src/test/run-pass/task-life-0.rs b/src/test/run-pass/task-life-0.rs index b60e3f2a4eeba..54aac31c7dee5 100644 --- a/src/test/run-pass/task-life-0.rs +++ b/src/test/run-pass/task-life-0.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/tempfile.rs b/src/test/run-pass/tempfile.rs index 077a0c46ecbf8..d42ce9793e0fa 100644 --- a/src/test/run-pass/tempfile.rs +++ b/src/test/run-pass/tempfile.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -// ignore-fast check-fast doesn't like 'extern mod' +// ignore-fast check-fast doesn't like 'extern crate' // ignore-win32 TempDir may cause IoError on windows: #10463 // These tests are here to exercise the functionality of the `tempfile` module. @@ -19,7 +19,7 @@ // they're in a different location than before. Hence, these tests are all run // serially here. -extern mod extra; +extern crate extra; use extra::tempfile::TempDir; use std::io::fs; diff --git a/src/test/run-pass/terminate-in-initializer.rs b/src/test/run-pass/terminate-in-initializer.rs index aaedb2d322be1..b63573f6103ba 100644 --- a/src/test/run-pass/terminate-in-initializer.rs +++ b/src/test/run-pass/terminate-in-initializer.rs @@ -13,7 +13,7 @@ // Issue #787 // Don't try to clean up uninitialized locals -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/test-ignore-cfg.rs b/src/test/run-pass/test-ignore-cfg.rs index 89579c541d250..eee667fdb0411 100644 --- a/src/test/run-pass/test-ignore-cfg.rs +++ b/src/test/run-pass/test-ignore-cfg.rs @@ -11,7 +11,7 @@ // compile-flags: --test --cfg ignorecfg // ignore-fast -extern mod extra; +extern crate extra; #[test] #[ignore(cfg(ignorecfg))] diff --git a/src/test/run-pass/test-runner-hides-main.rs b/src/test/run-pass/test-runner-hides-main.rs index 42810f3e0ee66..cdef159b3996d 100644 --- a/src/test/run-pass/test-runner-hides-main.rs +++ b/src/test/run-pass/test-runner-hides-main.rs @@ -12,7 +12,7 @@ // ignore-fast // ignore-win32 #10872 -extern mod extra; +extern crate extra; // Building as a test runner means that a synthetic main will be run, // not ours diff --git a/src/test/run-pass/threads.rs b/src/test/run-pass/threads.rs index 7df9dac219a1f..3e1d5b3684dc3 100644 --- a/src/test/run-pass/threads.rs +++ b/src/test/run-pass/threads.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/trait-bounds-in-arc.rs b/src/test/run-pass/trait-bounds-in-arc.rs index 4989a13957ae2..fa94f1012d026 100644 --- a/src/test/run-pass/trait-bounds-in-arc.rs +++ b/src/test/run-pass/trait-bounds-in-arc.rs @@ -15,7 +15,7 @@ // ignore-fast -extern mod sync; +extern crate sync; use sync::Arc; use std::task; diff --git a/src/test/run-pass/trait-default-method-xc-2.rs b/src/test/run-pass/trait-default-method-xc-2.rs index 777881f9360eb..ccd7c9b8a3af2 100644 --- a/src/test/run-pass/trait-default-method-xc-2.rs +++ b/src/test/run-pass/trait-default-method-xc-2.rs @@ -13,8 +13,8 @@ // aux-build:trait_default_method_xc_aux_2.rs -extern mod aux = "trait_default_method_xc_aux"; -extern mod aux2 = "trait_default_method_xc_aux_2"; +extern crate aux = "trait_default_method_xc_aux"; +extern crate aux2 = "trait_default_method_xc_aux_2"; use aux::A; use aux2::{a_struct, welp}; diff --git a/src/test/run-pass/trait-default-method-xc.rs b/src/test/run-pass/trait-default-method-xc.rs index 7ad658527c909..c0344136059df 100644 --- a/src/test/run-pass/trait-default-method-xc.rs +++ b/src/test/run-pass/trait-default-method-xc.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:trait_default_method_xc_aux.rs -extern mod aux = "trait_default_method_xc_aux"; +extern crate aux = "trait_default_method_xc_aux"; use aux::{A, TestEquality, Something}; use aux::B; diff --git a/src/test/run-pass/trait-inheritance-auto-xc-2.rs b/src/test/run-pass/trait-inheritance-auto-xc-2.rs index 4f5b6a783f513..bf6c429b6c80e 100644 --- a/src/test/run-pass/trait-inheritance-auto-xc-2.rs +++ b/src/test/run-pass/trait-inheritance-auto-xc-2.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:trait_inheritance_auto_xc_2_aux.rs -extern mod aux = "trait_inheritance_auto_xc_2_aux"; +extern crate aux = "trait_inheritance_auto_xc_2_aux"; // aux defines impls of Foo, Bar and Baz for A use aux::{Foo, Bar, Baz, A}; diff --git a/src/test/run-pass/trait-inheritance-auto-xc.rs b/src/test/run-pass/trait-inheritance-auto-xc.rs index dfaddea86c21c..ef72611e76f15 100644 --- a/src/test/run-pass/trait-inheritance-auto-xc.rs +++ b/src/test/run-pass/trait-inheritance-auto-xc.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:trait_inheritance_auto_xc_aux.rs -extern mod aux = "trait_inheritance_auto_xc_aux"; +extern crate aux = "trait_inheritance_auto_xc_aux"; use aux::{Foo, Bar, Baz, Quux}; diff --git a/src/test/run-pass/trait-inheritance-cross-trait-call-xc.rs b/src/test/run-pass/trait-inheritance-cross-trait-call-xc.rs index 1915a136afcaf..cdc0c5a80a9ba 100644 --- a/src/test/run-pass/trait-inheritance-cross-trait-call-xc.rs +++ b/src/test/run-pass/trait-inheritance-cross-trait-call-xc.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:trait_inheritance_cross_trait_call_xc_aux.rs -extern mod aux = "trait_inheritance_cross_trait_call_xc_aux"; +extern crate aux = "trait_inheritance_cross_trait_call_xc_aux"; use aux::Foo; diff --git a/src/test/run-pass/trait-inheritance-num.rs b/src/test/run-pass/trait-inheritance-num.rs index 49457d521613d..b7d5f9c6fd68d 100644 --- a/src/test/run-pass/trait-inheritance-num.rs +++ b/src/test/run-pass/trait-inheritance-num.rs @@ -10,7 +10,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use std::cmp::{Eq, Ord}; use std::num::NumCast; diff --git a/src/test/run-pass/trait-inheritance-num2.rs b/src/test/run-pass/trait-inheritance-num2.rs index eccafcf5be884..5e6dc7c67c8e6 100644 --- a/src/test/run-pass/trait-inheritance-num2.rs +++ b/src/test/run-pass/trait-inheritance-num2.rs @@ -12,7 +12,7 @@ // A more complex example of numeric extensions -extern mod extra; +extern crate extra; use std::cmp::{Eq, Ord}; diff --git a/src/test/run-pass/trait-inheritance-overloading-xc-exe.rs b/src/test/run-pass/trait-inheritance-overloading-xc-exe.rs index 838a5a337a347..faadc68f135bd 100644 --- a/src/test/run-pass/trait-inheritance-overloading-xc-exe.rs +++ b/src/test/run-pass/trait-inheritance-overloading-xc-exe.rs @@ -11,7 +11,7 @@ // ignore-fast - check-fast doesn't understand aux-build // aux-build:trait_inheritance_overloading_xc.rs -extern mod trait_inheritance_overloading_xc; +extern crate trait_inheritance_overloading_xc; use trait_inheritance_overloading_xc::{MyNum, MyInt}; fn f(x: T, y: T) -> (T, T, T) { diff --git a/src/test/run-pass/trait-typedef-cc.rs b/src/test/run-pass/trait-typedef-cc.rs index e50abf06ddfd7..62cda8ed82d75 100644 --- a/src/test/run-pass/trait-typedef-cc.rs +++ b/src/test/run-pass/trait-typedef-cc.rs @@ -10,7 +10,7 @@ // ignore-test FIXME: #3907 // aux-build:trait_typedef_cc.rs -extern mod trait_typedef_cc; +extern crate trait_typedef_cc; type Foo = trait_typedef_cc::Foo; diff --git a/src/test/run-pass/type-sizes.rs b/src/test/run-pass/type-sizes.rs index 2cdff23050db3..970a5c5011b2e 100644 --- a/src/test/run-pass/type-sizes.rs +++ b/src/test/run-pass/type-sizes.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod std; +extern crate std; use std::mem::size_of; struct t {a: u8, b: i8} diff --git a/src/test/run-pass/typeid-intrinsic.rs b/src/test/run-pass/typeid-intrinsic.rs index 1a386a0c76f59..71e19b51c7266 100644 --- a/src/test/run-pass/typeid-intrinsic.rs +++ b/src/test/run-pass/typeid-intrinsic.rs @@ -12,8 +12,8 @@ // aux-build:typeid-intrinsic.rs // aux-build:typeid-intrinsic2.rs -extern mod other1 = "typeid-intrinsic"; -extern mod other2 = "typeid-intrinsic2"; +extern crate other1 = "typeid-intrinsic"; +extern crate other2 = "typeid-intrinsic2"; use std::unstable::intrinsics; use std::unstable::intrinsics::TypeId; diff --git a/src/test/run-pass/unify-return-ty.rs b/src/test/run-pass/unify-return-ty.rs index 8bdce601b285c..fc0d4ce4b897b 100644 --- a/src/test/run-pass/unify-return-ty.rs +++ b/src/test/run-pass/unify-return-ty.rs @@ -11,7 +11,7 @@ // Tests that the tail expr in null() has its type // unified with the type *T, and so the type variable // in that type gets resolved. -extern mod extra; +extern crate extra; use std::cast; diff --git a/src/test/run-pass/unwind-box.rs b/src/test/run-pass/unwind-box.rs index 173919608de01..beaf76cafbcde 100644 --- a/src/test/run-pass/unwind-box.rs +++ b/src/test/run-pass/unwind-box.rs @@ -10,7 +10,7 @@ #[feature(managed_boxes)]; -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/unwind-resource.rs b/src/test/run-pass/unwind-resource.rs index e643a20436e0c..8143188b9770f 100644 --- a/src/test/run-pass/unwind-resource.rs +++ b/src/test/run-pass/unwind-resource.rs @@ -10,7 +10,7 @@ // ignore-fast -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/unwind-resource2.rs b/src/test/run-pass/unwind-resource2.rs index 38e5a122a12ac..176eb02105f72 100644 --- a/src/test/run-pass/unwind-resource2.rs +++ b/src/test/run-pass/unwind-resource2.rs @@ -10,7 +10,7 @@ #[feature(managed_boxes)]; -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/unwind-unique.rs b/src/test/run-pass/unwind-unique.rs index e2e64d7257596..dabe8c3450b86 100644 --- a/src/test/run-pass/unwind-unique.rs +++ b/src/test/run-pass/unwind-unique.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use std::task; diff --git a/src/test/run-pass/use-crate-name-alias.rs b/src/test/run-pass/use-crate-name-alias.rs index d9f40e5f1f3d8..9c53dde21ddbb 100644 --- a/src/test/run-pass/use-crate-name-alias.rs +++ b/src/test/run-pass/use-crate-name-alias.rs @@ -9,6 +9,6 @@ // except according to those terms. // Issue #1706 -extern mod stdlib = "extra"; +extern crate stdlib = "extra"; pub fn main() {} diff --git a/src/test/run-pass/use.rs b/src/test/run-pass/use.rs index a8646441e74bd..1d65a0a5e9e8c 100644 --- a/src/test/run-pass/use.rs +++ b/src/test/run-pass/use.rs @@ -15,9 +15,9 @@ #[allow(unused_imports)]; #[no_std]; -extern mod std; -extern mod zed = "std"; -extern mod bar = "std#0.10-pre"; +extern crate std; +extern crate zed = "std"; +extern crate bar = "std#0.10-pre"; use std::str; diff --git a/src/test/run-pass/use_inline_dtor.rs b/src/test/run-pass/use_inline_dtor.rs index a041cfc333440..9cb11c10e3ea8 100644 --- a/src/test/run-pass/use_inline_dtor.rs +++ b/src/test/run-pass/use_inline_dtor.rs @@ -11,7 +11,7 @@ // aux-build:inline_dtor.rs // ignore-fast -extern mod inline_dtor; +extern crate inline_dtor; pub fn main() { let _x = inline_dtor::Foo; diff --git a/src/test/run-pass/utf8_chars.rs b/src/test/run-pass/utf8_chars.rs index 4c86b5eb2bec8..3066a247e4e6b 100644 --- a/src/test/run-pass/utf8_chars.rs +++ b/src/test/run-pass/utf8_chars.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; use std::str; diff --git a/src/test/run-pass/vec-self-append.rs b/src/test/run-pass/vec-self-append.rs index ce70643cfc68e..e9fcfaaf2837f 100644 --- a/src/test/run-pass/vec-self-append.rs +++ b/src/test/run-pass/vec-self-append.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -extern mod extra; +extern crate extra; fn test_heap_to_heap() { // a spills onto the heap diff --git a/src/test/run-pass/xcrate-address-insignificant.rs b/src/test/run-pass/xcrate-address-insignificant.rs index 01ffdc1f2eff0..b231b859a066d 100644 --- a/src/test/run-pass/xcrate-address-insignificant.rs +++ b/src/test/run-pass/xcrate-address-insignificant.rs @@ -11,7 +11,7 @@ // ignore-fast check-fast doesn't like aux-build // aux-build:xcrate_address_insignificant.rs -extern mod foo = "xcrate_address_insignificant"; +extern crate foo = "xcrate_address_insignificant"; pub fn main() { assert_eq!(foo::foo::(), foo::bar()); diff --git a/src/test/run-pass/xcrate-static-addresses.rs b/src/test/run-pass/xcrate-static-addresses.rs index b1335d3572826..d3184968ee614 100644 --- a/src/test/run-pass/xcrate-static-addresses.rs +++ b/src/test/run-pass/xcrate-static-addresses.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:xcrate_static_addresses.rs -extern mod xcrate_static_addresses; +extern crate xcrate_static_addresses; use other = xcrate_static_addresses; diff --git a/src/test/run-pass/xcrate-trait-lifetime-param.rs b/src/test/run-pass/xcrate-trait-lifetime-param.rs index a26a3ebeb8c52..b5aae62841f71 100644 --- a/src/test/run-pass/xcrate-trait-lifetime-param.rs +++ b/src/test/run-pass/xcrate-trait-lifetime-param.rs @@ -11,7 +11,7 @@ // ignore-fast // aux-build:xcrate-trait-lifetime-param.rs -extern mod other = "xcrate-trait-lifetime-param"; +extern crate other = "xcrate-trait-lifetime-param"; struct Reader<'a> { b : &'a [u8] diff --git a/src/test/run-pass/xcrate-unit-struct.rs b/src/test/run-pass/xcrate-unit-struct.rs index 927881d7c17f7..3a440037cf82e 100644 --- a/src/test/run-pass/xcrate-unit-struct.rs +++ b/src/test/run-pass/xcrate-unit-struct.rs @@ -10,7 +10,7 @@ // aux-build:xcrate_unit_struct.rs // ignore-fast -extern mod xcrate_unit_struct; +extern crate xcrate_unit_struct; static s1: xcrate_unit_struct::Struct = xcrate_unit_struct::Struct; static s2: xcrate_unit_struct::Unit = xcrate_unit_struct::Unit;