]> git.lizzy.rs Git - rust.git/commitdiff
More fallout
authorNick Cameron <ncameron@mozilla.com>
Thu, 1 Jan 2015 04:40:24 +0000 (17:40 +1300)
committerNick Cameron <ncameron@mozilla.com>
Thu, 1 Jan 2015 21:28:19 +0000 (10:28 +1300)
47 files changed:
src/doc/guide.md
src/libcollections/slice.rs
src/libcollections/str.rs
src/libcore/array.rs
src/libcore/hash/mod.rs
src/liblibc/lib.rs
src/librand/chacha.rs
src/librand/distributions/ziggurat_tables.rs
src/librand/isaac.rs
src/librand/lib.rs
src/libregex_macros/lib.rs
src/librustc_trans/trans/builder.rs
src/librustc_trans/trans/cleanup.rs
src/libserialize/json.rs
src/libstd/c_str.rs
src/libstd/io/fs.rs
src/libstd/io/mem.rs
src/libstd/io/net/pipe.rs
src/libstd/io/net/tcp.rs
src/libstd/io/net/udp.rs
src/libstd/io/util.rs
src/libstd/rand/mod.rs
src/libstd/rand/os.rs
src/libstd/rand/reader.rs
src/libstd/rt/libunwind.rs
src/libstd/rt/unwind.rs
src/libstd/sys/common/net.rs
src/libstd/sys/unix/c.rs
src/libstd/sys/unix/os.rs
src/libstd/sys/unix/sync.rs
src/libstd/sys/windows/backtrace.rs
src/libstd/sys/windows/c.rs
src/libstd/sys/windows/os.rs
src/libstd/sys/windows/stack_overflow.rs
src/libsyntax/diagnostics/plugin.rs
src/test/compile-fail/array-old-syntax-1.rs
src/test/compile-fail/better-expected.rs
src/test/compile-fail/issue-17913.rs
src/test/compile-fail/issue-6977.rs
src/test/compile-fail/removed-syntax-fixed-vec.rs
src/test/compile-fail/removed-syntax-mut-vec-ty.rs
src/test/pretty/issue-4264.rs
src/test/run-pass/foreach-external-iterators-break.rs
src/test/run-pass/foreach-external-iterators-loop.rs
src/test/run-pass/foreach-external-iterators-nested.rs
src/test/run-pass/foreach-external-iterators.rs
src/test/run-pass/transmute-non-immediate-to-immediate.rs

index 289587b9ded1ed9eac55f8ce60097be427cf1b32..f4ec787a7949109c7a2a95801cfdf49ce958baa3 100644 (file)
@@ -1617,7 +1617,7 @@ value. In this example, each element of `a` will be initialized to `0i`:
 let a = [0i; 20]; // a: [int; 20]
 ```
 
-Arrays have type `[T,..N]`. We'll talk about this `T` notation later, when we
+Arrays have type `[TN]`. We'll talk about this `T` notation later, when we
 cover generics.
 
 You can get the number of elements in an array `a` with `a.len()`, and use
index 5f72fc696394ca7fe1c1aba977e29a2da9e358a4..61111d96bd064cf3a7f8e9b13d0cd2d9ec587ee1 100644 (file)
@@ -382,7 +382,7 @@ fn is_empty(&self) -> bool { self.len() == 0 }
     fn get_mut(&mut self, index: uint) -> Option<&mut T>;
 
     /// Work with `self` as a mut slice.
-    /// Primarily intended for getting a &mut [T] from a [T, ..N].
+    /// Primarily intended for getting a &mut [T] from a [TN].
     #[stable]
     fn as_mut_slice(&mut self) -> &mut [T];
 
@@ -2060,7 +2060,7 @@ fn test_sort() {
         }
 
         // shouldn't panic
-        let mut v: [uint, .. 0] = [];
+        let mut v: [uint; 0] = [];
         v.sort();
 
         let mut v = [0xDEADBEEFu];
@@ -2072,7 +2072,7 @@ fn test_sort() {
     fn test_sort_stability() {
         for len in range(4i, 25) {
             for _ in range(0u, 10) {
-                let mut counts = [0i, .. 10];
+                let mut counts = [0i; 10];
 
                 // create a vector like [(6, 1), (5, 1), (6, 2), ...],
                 // where the first item of each tuple is random, but
index 7caeb563db724bb4763031a9fbee36a03873d7ec..129ba77d9f7a6022a8673f8d315474ff9d212d39 100644 (file)
@@ -2743,7 +2743,7 @@ fn test_graphemes() {
         use core::iter::order;
         // official Unicode test data
         // from http://www.unicode.org/Public/UCD/latest/ucd/auxiliary/GraphemeBreakTest.txt
-        let test_same: [(_, &[_]), .. 325] = [
+        let test_same: [(_, &[_]); 325] = [
             ("\u{20}\u{20}", &["\u{20}", "\u{20}"]),
             ("\u{20}\u{308}\u{20}", &["\u{20}\u{308}", "\u{20}"]),
             ("\u{20}\u{D}", &["\u{20}", "\u{D}"]),
@@ -3075,7 +3075,7 @@ fn test_graphemes() {
             ("\u{646}\u{200D}\u{20}", &["\u{646}\u{200D}", "\u{20}"]),
         ];
 
-        let test_diff: [(_, &[_], &[_]), .. 23] = [
+        let test_diff: [(_, &[_], &[_]); 23] = [
             ("\u{20}\u{903}", &["\u{20}\u{903}"], &["\u{20}", "\u{903}"]), ("\u{20}\u{308}\u{903}",
             &["\u{20}\u{308}\u{903}"], &["\u{20}\u{308}", "\u{903}"]), ("\u{D}\u{308}\u{903}",
             &["\u{D}", "\u{308}\u{903}"], &["\u{D}", "\u{308}", "\u{903}"]), ("\u{A}\u{308}\u{903}",
index 88e23377046f12419cfd1c93c52f4f7600fc4ad4..28563a60b6164eaa4593dc57ecb45f686148f36b 100644 (file)
@@ -26,33 +26,33 @@ macro_rules! array_impls {
     ($($N:expr)+) => {
         $(
             #[stable]
-            impl<T:Copy> Clone for [T, ..$N] {
-                fn clone(&self) -> [T, ..$N] {
+            impl<T:Copy> Clone for [T$N] {
+                fn clone(&self) -> [T$N] {
                     *self
                 }
             }
 
             #[unstable = "waiting for Show to stabilize"]
-            impl<T:fmt::Show> fmt::Show for [T, ..$N] {
+            impl<T:fmt::Show> fmt::Show for [T$N] {
                 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
                     fmt::Show::fmt(&self[], f)
                 }
             }
 
             #[stable]
-            impl<A, B> PartialEq<[B, ..$N]> for [A, ..$N] where A: PartialEq<B> {
+            impl<A, B> PartialEq<[B; $N]> for [A; $N] where A: PartialEq<B> {
                 #[inline]
-                fn eq(&self, other: &[B, ..$N]) -> bool {
+                fn eq(&self, other: &[B$N]) -> bool {
                     self[] == other[]
                 }
                 #[inline]
-                fn ne(&self, other: &[B, ..$N]) -> bool {
+                fn ne(&self, other: &[B$N]) -> bool {
                     self[] != other[]
                 }
             }
 
             #[stable]
-            impl<'a, A, B, Rhs> PartialEq<Rhs> for [A, ..$N] where
+            impl<'a, A, B, Rhs> PartialEq<Rhs> for [A$N] where
                 A: PartialEq<B>,
                 Rhs: Deref<[B]>,
             {
@@ -63,47 +63,47 @@ fn ne(&self, other: &Rhs) -> bool { PartialEq::ne(self[], &**other) }
             }
 
             #[stable]
-            impl<'a, A, B, Lhs> PartialEq<[B, ..$N]> for Lhs where
+            impl<'a, A, B, Lhs> PartialEq<[B$N]> for Lhs where
                 A: PartialEq<B>,
                 Lhs: Deref<[A]>
             {
                 #[inline(always)]
-                fn eq(&self, other: &[B, ..$N]) -> bool { PartialEq::eq(&**self, other[]) }
+                fn eq(&self, other: &[B$N]) -> bool { PartialEq::eq(&**self, other[]) }
                 #[inline(always)]
-                fn ne(&self, other: &[B, ..$N]) -> bool { PartialEq::ne(&**self, other[]) }
+                fn ne(&self, other: &[B$N]) -> bool { PartialEq::ne(&**self, other[]) }
             }
 
             #[stable]
-            impl<T:Eq> Eq for [T, ..$N] { }
+            impl<T:Eq> Eq for [T$N] { }
 
             #[stable]
-            impl<T:PartialOrd> PartialOrd for [T, ..$N] {
+            impl<T:PartialOrd> PartialOrd for [T$N] {
                 #[inline]
-                fn partial_cmp(&self, other: &[T, ..$N]) -> Option<Ordering> {
+                fn partial_cmp(&self, other: &[T$N]) -> Option<Ordering> {
                     PartialOrd::partial_cmp(&self[], &other[])
                 }
                 #[inline]
-                fn lt(&self, other: &[T, ..$N]) -> bool {
+                fn lt(&self, other: &[T$N]) -> bool {
                     PartialOrd::lt(&self[], &other[])
                 }
                 #[inline]
-                fn le(&self, other: &[T, ..$N]) -> bool {
+                fn le(&self, other: &[T$N]) -> bool {
                     PartialOrd::le(&self[], &other[])
                 }
                 #[inline]
-                fn ge(&self, other: &[T, ..$N]) -> bool {
+                fn ge(&self, other: &[T$N]) -> bool {
                     PartialOrd::ge(&self[], &other[])
                 }
                 #[inline]
-                fn gt(&self, other: &[T, ..$N]) -> bool {
+                fn gt(&self, other: &[T$N]) -> bool {
                     PartialOrd::gt(&self[], &other[])
                 }
             }
 
             #[stable]
-            impl<T:Ord> Ord for [T, ..$N] {
+            impl<T:Ord> Ord for [T$N] {
                 #[inline]
-                fn cmp(&self, other: &[T, ..$N]) -> Ordering {
+                fn cmp(&self, other: &[T$N]) -> Ordering {
                     Ord::cmp(&self[], &other[])
                 }
             }
index c1aa605a4558b05e15fe0b244703c4d6b38011b0..d4d241752f20b6fe1edb0e01158c2ffb3f9490d8 100644 (file)
@@ -100,7 +100,7 @@ macro_rules! impl_hash {
         impl<S: Writer> Hash<S> for $ty {
             #[inline]
             fn hash(&self, state: &mut S) {
-                let a: [u8, ..::$ty::BYTES] = unsafe {
+                let a: [u8::$ty::BYTES] = unsafe {
                     mem::transmute((*self as $uty).to_le() as $ty)
                 };
                 state.write(a.as_slice())
index ad8895924f9596371e3a96d21c06b070444f1617..9faaedc45f3b10359104febec977e9f9b0f89a7f 100644 (file)
@@ -1632,7 +1632,7 @@ pub mod extra {
                 #[repr(C)]
                 #[deriving(Copy)] pub struct WSAPROTOCOLCHAIN {
                     pub ChainLen: c_int,
-                    pub ChainEntries: [DWORD, ..MAX_PROTOCOL_CHAIN as uint],
+                    pub ChainEntries: [DWORDMAX_PROTOCOL_CHAIN as uint],
                 }
 
                 pub type LPWSAPROTOCOLCHAIN = *mut WSAPROTOCOLCHAIN;
@@ -1658,7 +1658,7 @@ pub mod extra {
                     pub iSecurityScheme: c_int,
                     pub dwMessageSize: DWORD,
                     pub dwProviderReserved: DWORD,
-                    pub szProtocol: [u8, ..(WSAPROTOCOL_LEN as uint) + 1u],
+                    pub szProtocol: [u8(WSAPROTOCOL_LEN as uint) + 1u],
                 }
 
                 pub type LPWSAPROTOCOL_INFO = *mut WSAPROTOCOL_INFO;
index 0cf9ce851085ff8c381c458c641889d09ab03ae2..49577cd279bf84bb22c341ff236448ba237f3ffe 100644 (file)
 
 #[deriving(Copy)]
 pub struct ChaChaRng {
-    buffer:  [u32, ..STATE_WORDS], // Internal buffer of output
-    state:   [u32, ..STATE_WORDS], // Initial state
+    buffer:  [u32STATE_WORDS], // Internal buffer of output
+    state:   [u32STATE_WORDS], // Initial state
     index:   uint,                 // Index into state
 }
 
 static EMPTY: ChaChaRng = ChaChaRng {
-    buffer:  [0, ..STATE_WORDS],
-    state:   [0, ..STATE_WORDS],
+    buffer:  [0STATE_WORDS],
+    state:   [0STATE_WORDS],
     index:   STATE_WORDS
 };
 
@@ -68,7 +68,7 @@ macro_rules! double_round{
 }
 
 #[inline]
-fn core(output: &mut [u32, ..STATE_WORDS], input: &[u32, ..STATE_WORDS]) {
+fn core(output: &mut [u32; STATE_WORDS], input: &[u32; STATE_WORDS]) {
     *output = *input;
 
     for _ in range(0, CHACHA_ROUNDS / 2) {
@@ -86,7 +86,7 @@ impl ChaChaRng {
     /// fixed key of 8 zero words.
     pub fn new_unseeded() -> ChaChaRng {
         let mut rng = EMPTY;
-        rng.init(&[0, ..KEY_WORDS]);
+        rng.init(&[0KEY_WORDS]);
         rng
     }
 
@@ -124,7 +124,7 @@ pub fn set_counter(&mut self, counter_low: u64, counter_high: u64) {
     /// ```
     /// [1]: Daniel J. Bernstein. [*Extending the Salsa20
     /// nonce.*](http://cr.yp.to/papers.html#xsalsa)
-    fn init(&mut self, key: &[u32, ..KEY_WORDS]) {
+    fn init(&mut self, key: &[u32KEY_WORDS]) {
         self.state[0] = 0x61707865;
         self.state[1] = 0x3320646E;
         self.state[2] = 0x79622D32;
@@ -174,7 +174,7 @@ impl<'a> SeedableRng<&'a [u32]> for ChaChaRng {
 
     fn reseed(&mut self, seed: &'a [u32]) {
         // reset state
-        self.init(&[0u32, ..KEY_WORDS]);
+        self.init(&[0u32KEY_WORDS]);
         // set key in place
         let key = self.state.slice_mut(4, 4+KEY_WORDS);
         for (k, s) in key.iter_mut().zip(seed.iter()) {
@@ -195,7 +195,7 @@ fn from_seed(seed: &'a [u32]) -> ChaChaRng {
 
 impl Rand for ChaChaRng {
     fn rand<R: Rng>(other: &mut R) -> ChaChaRng {
-        let mut key : [u32, ..KEY_WORDS] = [0, ..KEY_WORDS];
+        let mut key : [u32; KEY_WORDS] = [0; KEY_WORDS];
         for word in key.iter_mut() {
             *word = other.gen();
         }
index 049ef3dbb5936933b894b9dfe9891fa872affa97..a108fd70d1ca9d6410eb60bc1f048dbacf68b211 100644 (file)
@@ -11,9 +11,9 @@
 // Tables for distributions which are sampled using the ziggurat
 // algorithm. Autogenerated by `ziggurat_tables.py`.
 
-pub type ZigTable = &'static [f64, .. 257];
+pub type ZigTable = &'static [f64; 257];
 pub static ZIG_NORM_R: f64 = 3.654152885361008796;
-pub static ZIG_NORM_X: [f64, .. 257] =
+pub static ZIG_NORM_X: [f64; 257] =
     [3.910757959537090045, 3.654152885361008796, 3.449278298560964462, 3.320244733839166074,
      3.224575052047029100, 3.147889289517149969, 3.083526132001233044, 3.027837791768635434,
      2.978603279880844834, 2.934366867207854224, 2.894121053612348060, 2.857138730872132548,
@@ -79,7 +79,7 @@
      0.487443966121754335, 0.463634336771763245, 0.437518402186662658, 0.408389134588000746,
      0.375121332850465727, 0.335737519180459465, 0.286174591747260509, 0.215241895913273806,
      0.000000000000000000];
-pub static ZIG_NORM_F: [f64, .. 257] =
+pub static ZIG_NORM_F: [f64; 257] =
     [0.000477467764586655, 0.001260285930498598, 0.002609072746106363, 0.004037972593371872,
      0.005522403299264754, 0.007050875471392110, 0.008616582769422917, 0.010214971439731100,
      0.011842757857943104, 0.013497450601780807, 0.015177088307982072, 0.016880083152595839,
      0.932060075968990209, 0.945198953453078028, 0.959879091812415930, 0.977101701282731328,
      1.000000000000000000];
 pub static ZIG_EXP_R: f64 = 7.697117470131050077;
-pub static ZIG_EXP_X: [f64, .. 257] =
+pub static ZIG_EXP_X: [f64; 257] =
     [8.697117470131052741, 7.697117470131050077, 6.941033629377212577, 6.478378493832569696,
      6.144164665772472667, 5.882144315795399869, 5.666410167454033697, 5.482890627526062488,
      5.323090505754398016, 5.181487281301500047, 5.054288489981304089, 4.938777085901250530,
      0.253658363385912022, 0.233790483059674731, 0.212671510630966620, 0.189958689622431842,
      0.165127622564187282, 0.137304980940012589, 0.104838507565818778, 0.063852163815001570,
      0.000000000000000000];
-pub static ZIG_EXP_F: [f64, .. 257] =
+pub static ZIG_EXP_F: [f64; 257] =
     [0.000167066692307963, 0.000454134353841497, 0.000967269282327174, 0.001536299780301573,
      0.002145967743718907, 0.002788798793574076, 0.003460264777836904, 0.004157295120833797,
      0.004877655983542396, 0.005619642207205489, 0.006381905937319183, 0.007163353183634991,
index a76e5ebd08a8493ae4ff217f9863193350515e16..1fe435a59adcbd7186205c2316592485339c0bf9 100644 (file)
@@ -32,8 +32,8 @@
 #[deriving(Copy)]
 pub struct IsaacRng {
     cnt: u32,
-    rsl: [u32, ..RAND_SIZE_UINT],
-    mem: [u32, ..RAND_SIZE_UINT],
+    rsl: [u32RAND_SIZE_UINT],
+    mem: [u32RAND_SIZE_UINT],
     a: u32,
     b: u32,
     c: u32
@@ -41,8 +41,8 @@ pub struct IsaacRng {
 
 static EMPTY: IsaacRng = IsaacRng {
     cnt: 0,
-    rsl: [0, ..RAND_SIZE_UINT],
-    mem: [0, ..RAND_SIZE_UINT],
+    rsl: [0RAND_SIZE_UINT],
+    mem: [0RAND_SIZE_UINT],
     a: 0, b: 0, c: 0
 };
 
@@ -267,8 +267,8 @@ fn rand<R: Rng>(other: &mut R) -> IsaacRng {
 #[deriving(Copy)]
 pub struct Isaac64Rng {
     cnt: uint,
-    rsl: [u64, .. RAND_SIZE_64],
-    mem: [u64, .. RAND_SIZE_64],
+    rsl: [u64; RAND_SIZE_64],
+    mem: [u64; RAND_SIZE_64],
     a: u64,
     b: u64,
     c: u64,
@@ -276,8 +276,8 @@ pub struct Isaac64Rng {
 
 static EMPTY_64: Isaac64Rng = Isaac64Rng {
     cnt: 0,
-    rsl: [0, .. RAND_SIZE_64],
-    mem: [0, .. RAND_SIZE_64],
+    rsl: [0; RAND_SIZE_64],
+    mem: [0; RAND_SIZE_64],
     a: 0, b: 0, c: 0,
 };
 
@@ -358,7 +358,7 @@ fn isaac64(&mut self) {
         let mut a = self.a;
         let mut b = self.b + self.c;
         const MIDPOINT: uint =  RAND_SIZE_64 / 2;
-        const MP_VEC: [(uint, uint), .. 2] = [(0,MIDPOINT), (MIDPOINT, 0)];
+        const MP_VEC: [(uint, uint); 2] = [(0,MIDPOINT), (MIDPOINT, 0)];
         macro_rules! ind (
             ($x:expr) => {
                 *self.mem.get_unchecked(($x as uint >> 3) & (RAND_SIZE_64 - 1))
index 59f86db73c903ccf6c3a9acf3e376ecb3f1ebb6f..568d245911826cbe0a38bdc939515eb007646bf2 100644 (file)
@@ -140,7 +140,7 @@ fn next_f64(&mut self) -> f64 {
     /// ```rust
     /// use std::rand::{thread_rng, Rng};
     ///
-    /// let mut v = [0u8, .. 13579];
+    /// let mut v = [0u8; 13579];
     /// thread_rng().fill_bytes(&mut v);
     /// println!("{}", v.as_slice());
     /// ```
@@ -429,9 +429,9 @@ fn next_u32(&mut self) -> u32 {
     }
 }
 
-impl SeedableRng<[u32, .. 4]> for XorShiftRng {
+impl SeedableRng<[u32; 4]> for XorShiftRng {
     /// Reseed an XorShiftRng. This will panic if `seed` is entirely 0.
-    fn reseed(&mut self, seed: [u32, .. 4]) {
+    fn reseed(&mut self, seed: [u32; 4]) {
         assert!(!seed.iter().all(|&x| x == 0),
                 "XorShiftRng.reseed called with an all zero seed.");
 
@@ -442,7 +442,7 @@ fn reseed(&mut self, seed: [u32, .. 4]) {
     }
 
     /// Create a new XorShiftRng. This will panic if `seed` is entirely 0.
-    fn from_seed(seed: [u32, .. 4]) -> XorShiftRng {
+    fn from_seed(seed: [u32; 4]) -> XorShiftRng {
         assert!(!seed.iter().all(|&x| x == 0),
                 "XorShiftRng::from_seed called with an all zero seed.");
 
index bf1095d21b2f5ac69a9875ca6bb721c814425908..0baa5e6c24f22ab1efdc6c3538c6f0f4a328d07c 100644 (file)
@@ -169,7 +169,7 @@ fn exec<'t>(which: ::regex::native::MatchKind, input: &'t str,
         chars: CharReader::new(input),
     }.run(start, end);
 
-    type Captures = [Option<uint>, ..$num_cap_locs];
+    type Captures = [Option<uint>$num_cap_locs];
 
     struct Nfa<'t> {
         which: MatchKind,
@@ -250,8 +250,8 @@ struct Thread {
 
     struct Threads {
         which: MatchKind,
-        queue: [Thread, ..$num_insts],
-        sparse: [uint, ..$num_insts],
+        queue: [Thread$num_insts],
+        sparse: [uint$num_insts],
         size: uint,
     }
 
index 5249f59d78f750b28ab2a1c001a41adda06f27b7..b39dbd71117e818b933e64f2b0d9aaeb134944cc 100644 (file)
@@ -547,7 +547,7 @@ pub fn gepi(&self, base: ValueRef, ixs: &[uint]) -> ValueRef {
         // Small vector optimization. This should catch 100% of the cases that
         // we care about.
         if ixs.len() < 16 {
-            let mut small_vec = [ C_i32(self.ccx, 0), ..16 ];
+            let mut small_vec = [ C_i32(self.ccx, 0)16 ];
             for (small_vec_e, &ix) in small_vec.iter_mut().zip(ixs.iter()) {
                 *small_vec_e = C_i32(self.ccx, ix as i32);
             }
index b4deea4c72fc812a12828e9fb934b98d72eb756d..8ac427dd06124c75c93d457707cd3fc210e2e6ce 100644 (file)
@@ -63,7 +63,7 @@ pub struct CustomScopeIndex {
 pub enum CleanupScopeKind<'blk, 'tcx: 'blk> {
     CustomScopeKind,
     AstScopeKind(ast::NodeId),
-    LoopScopeKind(ast::NodeId, [Block<'blk, 'tcx>, ..EXIT_MAX])
+    LoopScopeKind(ast::NodeId, [Block<'blk, 'tcx>EXIT_MAX])
 }
 
 impl<'blk, 'tcx: 'blk> fmt::Show for CleanupScopeKind<'blk, 'tcx> {
@@ -146,7 +146,7 @@ fn push_ast_cleanup_scope(&self, debug_loc: NodeInfo) {
 
     fn push_loop_cleanup_scope(&self,
                                id: ast::NodeId,
-                               exits: [Block<'blk, 'tcx>, ..EXIT_MAX]) {
+                               exits: [Block<'blk, 'tcx>EXIT_MAX]) {
         debug!("push_loop_cleanup_scope({})",
                self.ccx.tcx().map.node_to_string(id));
         assert_eq!(Some(id), self.top_ast_scope());
@@ -1058,7 +1058,7 @@ pub trait CleanupMethods<'blk, 'tcx> {
     fn push_ast_cleanup_scope(&self, id: NodeInfo);
     fn push_loop_cleanup_scope(&self,
                                id: ast::NodeId,
-                               exits: [Block<'blk, 'tcx>, ..EXIT_MAX]);
+                               exits: [Block<'blk, 'tcx>EXIT_MAX]);
     fn push_custom_cleanup_scope(&self) -> CustomScopeIndex;
     fn push_custom_cleanup_scope_with_debug_loc(&self,
                                                 debug_loc: NodeInfo)
index d88bc88dcbae5cce94d63d347b3399f83cc7aeb9..8a9c2eebf3a5325db027fdad1c508e4dc58c09be 100644 (file)
@@ -392,7 +392,7 @@ fn escape_str(writer: &mut io::Writer, v: &str) -> Result<(), io::IoError> {
 }
 
 fn escape_char(writer: &mut io::Writer, v: char) -> Result<(), io::IoError> {
-    let mut buf = [0, .. 4];
+    let mut buf = [0; 4];
     let len = v.encode_utf8(&mut buf).unwrap();
     escape_bytes(writer, buf[mut ..len])
 }
index 4e22fc6008037cc41cd50ce77218e57954e06834..46498610e560448242951eeb504e8af32414a3b6 100644 (file)
@@ -454,7 +454,7 @@ unsafe fn with_c_str<T, F>(v: &[u8], checked: bool, f: F) -> T where
     F: FnOnce(*const libc::c_char) -> T,
 {
     let c_str = if v.len() < BUF_LEN {
-        let mut buf: [u8, .. BUF_LEN] = mem::uninitialized();
+        let mut buf: [u8; BUF_LEN] = mem::uninitialized();
         slice::bytes::copy_memory(&mut buf, v);
         buf[v.len()] = 0;
 
index f6fb7ec435f14d97eb6880cf9d5978b240ad1c8f..7fa6ebc6e3bac0837633496428d44f9f6721d7ab 100644 (file)
@@ -882,7 +882,7 @@ fn file_test_io_smoke_test() {
         }
         {
             let mut read_stream = File::open_mode(filename, Open, Read);
-            let mut read_buf = [0, .. 1028];
+            let mut read_buf = [0; 1028];
             let read_str = match check!(read_stream.read(&mut read_buf)) {
                 -1|0 => panic!("shouldn't happen"),
                 n => str::from_utf8(read_buf[..n]).unwrap().to_string()
@@ -922,7 +922,7 @@ fn file_test_iounlinking_invalid_path_should_raise_condition() {
     #[test]
     fn file_test_io_non_positional_read() {
         let message: &str = "ten-four";
-        let mut read_mem = [0, .. 8];
+        let mut read_mem = [0; 8];
         let tmpdir = tmpdir();
         let filename = &tmpdir.join("file_rt_io_file_test_positional.txt");
         {
@@ -948,7 +948,7 @@ fn file_test_io_non_positional_read() {
     #[test]
     fn file_test_io_seek_and_tell_smoke_test() {
         let message = "ten-four";
-        let mut read_mem = [0, .. 4];
+        let mut read_mem = [0; 4];
         let set_cursor = 4 as u64;
         let mut tell_pos_pre_read;
         let mut tell_pos_post_read;
@@ -978,7 +978,7 @@ fn file_test_io_seek_and_write() {
         let overwrite_msg =    "-the-bar!!";
         let final_msg =     "foo-the-bar!!";
         let seek_idx = 3i;
-        let mut read_mem = [0, .. 13];
+        let mut read_mem = [0; 13];
         let tmpdir = tmpdir();
         let filename = &tmpdir.join("file_rt_io_file_test_seek_and_write.txt");
         {
@@ -1003,7 +1003,7 @@ fn file_test_io_seek_shakedown() {
         let chunk_one: &str = "qwer";
         let chunk_two: &str = "asdf";
         let chunk_three: &str = "zxcv";
-        let mut read_mem = [0, .. 4];
+        let mut read_mem = [0; 4];
         let tmpdir = tmpdir();
         let filename = &tmpdir.join("file_rt_io_file_test_seek_shakedown.txt");
         {
@@ -1105,7 +1105,7 @@ fn file_test_directoryinfo_readdir() {
             check!(w.write(msg));
         }
         let files = check!(readdir(dir));
-        let mut mem = [0u8, .. 4];
+        let mut mem = [0u8; 4];
         for f in files.iter() {
             {
                 let n = f.filestem_str();
@@ -1137,7 +1137,7 @@ fn file_test_walk_dir() {
         check!(File::create(&dir2.join("14")));
 
         let mut files = check!(walk_dir(dir));
-        let mut cur = [0u8, .. 2];
+        let mut cur = [0u8; 2];
         for f in files {
             let stem = f.filestem_str().unwrap();
             let root = stem.as_bytes()[0] - b'0';
index 9d73cae094d9dfb52316d73081d4b9a64bbff2ae..f8ea373f8f456794abda187489bbb7a42200e619 100644 (file)
@@ -725,9 +725,9 @@ fn bench_mem_reader(b: &mut Bencher) {
             {
                 let mut rdr = MemReader::new(buf);
                 for _i in range(0u, 10) {
-                    let mut buf = [0 as u8, .. 10];
+                    let mut buf = [0 as u8; 10];
                     rdr.read(&mut buf).unwrap();
-                    assert_eq!(buf.as_slice(), [5, .. 10].as_slice());
+                    assert_eq!(buf.as_slice(), [5; 10].as_slice());
                 }
             }
         });
@@ -740,10 +740,10 @@ fn bench_buf_writer(b: &mut Bencher) {
             {
                 let mut wr = BufWriter::new(&mut buf);
                 for _i in range(0u, 10) {
-                    wr.write(&[5, .. 10]).unwrap();
+                    wr.write(&[5; 10]).unwrap();
                 }
             }
-            assert_eq!(buf.as_slice(), [5, .. 100].as_slice());
+            assert_eq!(buf.as_slice(), [5; 100].as_slice());
         });
     }
 
@@ -754,9 +754,9 @@ fn bench_buf_reader(b: &mut Bencher) {
             {
                 let mut rdr = BufReader::new(&buf);
                 for _i in range(0u, 10) {
-                    let mut buf = [0 as u8, .. 10];
+                    let mut buf = [0 as u8; 10];
                     rdr.read(&mut buf).unwrap();
-                    assert_eq!(buf, [5, .. 10]);
+                    assert_eq!(buf, [5; 10]);
                 }
             }
         });
index 93f37a8c98ff86a6401b47eb8b21a2e88e7550aa..6ce66c3273bd6c2acb64ab0af2377de344bb3952 100644 (file)
@@ -672,7 +672,7 @@ fn readwrite_timeouts() {
 
         s.set_timeout(Some(20));
         for i in range(0u, 1001) {
-            match s.write(&[0, .. 128 * 1024]) {
+            match s.write(&[0; 128 * 1024]) {
                 Ok(()) | Err(IoError { kind: ShortWrite(..), .. }) => {},
                 Err(IoError { kind: TimedOut, .. }) => break,
                 Err(e) => panic!("{}", e),
@@ -701,7 +701,7 @@ fn read_timeouts() {
             rx.recv();
             let mut amt = 0;
             while amt < 100 * 128 * 1024 {
-                match s.read(&mut [0, ..128 * 1024]) {
+                match s.read(&mut [0;128 * 1024]) {
                     Ok(n) => { amt += n; }
                     Err(e) => panic!("{}", e),
                 }
@@ -716,7 +716,7 @@ fn read_timeouts() {
 
         tx.send(());
         for _ in range(0u, 100) {
-            assert!(s.write(&[0, ..128 * 1024]).is_ok());
+            assert!(s.write(&[0;128 * 1024]).is_ok());
         }
     }
 
@@ -735,7 +735,7 @@ fn write_timeouts() {
         let mut s = a.accept().unwrap();
         s.set_write_timeout(Some(20));
         for i in range(0u, 1001) {
-            match s.write(&[0, .. 128 * 1024]) {
+            match s.write(&[0; 128 * 1024]) {
                 Ok(()) | Err(IoError { kind: ShortWrite(..), .. }) => {},
                 Err(IoError { kind: TimedOut, .. }) => break,
                 Err(e) => panic!("{}", e),
index 4706ab35d1d3f14fb44aa0109f6102ead1fb7d91..826f492d85d3135f061963b85c23c9b820080e66 100644 (file)
@@ -1256,7 +1256,7 @@ fn readwrite_timeouts() {
 
         s.set_timeout(Some(20));
         for i in range(0i, 1001) {
-            match s.write(&[0, .. 128 * 1024]) {
+            match s.write(&[0; 128 * 1024]) {
                 Ok(()) | Err(IoError { kind: ShortWrite(..), .. }) => {},
                 Err(IoError { kind: TimedOut, .. }) => break,
                 Err(e) => panic!("{}", e),
@@ -1280,7 +1280,7 @@ fn read_timeouts() {
             rx.recv();
             let mut amt = 0;
             while amt < 100 * 128 * 1024 {
-                match s.read(&mut [0, ..128 * 1024]) {
+                match s.read(&mut [0;128 * 1024]) {
                     Ok(n) => { amt += n; }
                     Err(e) => panic!("{}", e),
                 }
@@ -1295,7 +1295,7 @@ fn read_timeouts() {
 
         tx.send(());
         for _ in range(0i, 100) {
-            assert!(s.write(&[0, ..128 * 1024]).is_ok());
+            assert!(s.write(&[0;128 * 1024]).is_ok());
         }
     }
 
@@ -1314,7 +1314,7 @@ fn write_timeouts() {
         let mut s = a.accept().unwrap();
         s.set_write_timeout(Some(20));
         for i in range(0i, 1001) {
-            match s.write(&[0, .. 128 * 1024]) {
+            match s.write(&[0; 128 * 1024]) {
                 Ok(()) | Err(IoError { kind: ShortWrite(..), .. }) => {},
                 Err(IoError { kind: TimedOut, .. }) => break,
                 Err(e) => panic!("{}", e),
index 62868afa00a31338d4e97ef16517d4270de70d71..11c2f956c355259d922bba4c5eecceab72f55bf0 100644 (file)
@@ -599,7 +599,7 @@ fn send_to_timeout() {
 
         a.set_write_timeout(Some(1000));
         for _ in range(0u, 100) {
-            match a.send_to(&[0, ..4*1024], addr2) {
+            match a.send_to(&[0;4*1024], addr2) {
                 Ok(()) | Err(IoError { kind: ShortWrite(..), .. }) => {},
                 Err(IoError { kind: TimedOut, .. }) => break,
                 Err(e) => panic!("other error: {}", e),
index f88e8d7e7e3b4f000e11027de7b8d0a9d241c318..9840412160d9fb431e33d0c5bb0f9e99291f7be8 100644 (file)
@@ -235,7 +235,7 @@ fn read(&mut self, buf: &mut [u8]) -> io::IoResult<uint> {
 
 /// Copies all data from a `Reader` to a `Writer`.
 pub fn copy<R: Reader, W: Writer>(r: &mut R, w: &mut W) -> io::IoResult<()> {
-    let mut buf = [0, ..super::DEFAULT_BUF_SIZE];
+    let mut buf = [0super::DEFAULT_BUF_SIZE];
     loop {
         let len = match r.read(&mut buf) {
             Ok(len) => len,
index d4f72a53aec1b7651928ec72a4f26add13014bee..f665d150f387831334793ce6b9bda8dcc586d912 100644 (file)
@@ -669,7 +669,7 @@ fn rand_std(b: &mut Bencher) {
     #[bench]
     fn rand_shuffle_100(b: &mut Bencher) {
         let mut rng = weak_rng();
-        let x : &mut[uint] = &mut [1,..100];
+        let x : &mut[uint] = &mut [1100];
         b.iter(|| {
             rng.shuffle(x);
         })
index 3b3e9ae627595bd725b62215ec7b8d1ef58132fa..ca36f2d8997b1df67dc3f00468a55753a1243132 100644 (file)
@@ -217,12 +217,12 @@ pub fn new() -> IoResult<OsRng> {
 
     impl Rng for OsRng {
         fn next_u32(&mut self) -> u32 {
-            let mut v = [0u8, .. 4];
+            let mut v = [0u8; 4];
             self.fill_bytes(&mut v);
             unsafe { mem::transmute(v) }
         }
         fn next_u64(&mut self) -> u64 {
-            let mut v = [0u8, .. 8];
+            let mut v = [0u8; 8];
             self.fill_bytes(&mut v);
             unsafe { mem::transmute(v) }
         }
@@ -304,12 +304,12 @@ pub fn new() -> IoResult<OsRng> {
 
     impl Rng for OsRng {
         fn next_u32(&mut self) -> u32 {
-            let mut v = [0u8, .. 4];
+            let mut v = [0u8; 4];
             self.fill_bytes(&mut v);
             unsafe { mem::transmute(v) }
         }
         fn next_u64(&mut self) -> u64 {
-            let mut v = [0u8, .. 8];
+            let mut v = [0u8; 8];
             self.fill_bytes(&mut v);
             unsafe { mem::transmute(v) }
         }
@@ -351,7 +351,7 @@ fn test_os_rng() {
         r.next_u32();
         r.next_u64();
 
-        let mut v = [0u8, .. 1000];
+        let mut v = [0u8; 1000];
         r.fill_bytes(&mut v);
     }
 
@@ -371,7 +371,7 @@ fn test_os_rng_tasks() {
                 // as possible (XXX: is this a good test?)
                 let mut r = OsRng::new().unwrap();
                 Thread::yield_now();
-                let mut v = [0u8, .. 1000];
+                let mut v = [0u8; 1000];
 
                 for _ in range(0u, 100) {
                     r.next_u32();
index 7298b2ef0acc745cf2d8532c8787ee9b2596a4e2..15e63aa19eabc43312ffeae6ed3074d2cebe11cc 100644 (file)
@@ -105,7 +105,7 @@ fn test_reader_rng_u32() {
     #[test]
     fn test_reader_rng_fill_bytes() {
         let v = [1u8, 2, 3, 4, 5, 6, 7, 8];
-        let mut w = [0u8, .. 8];
+        let mut w = [0u8; 8];
 
         let mut rng = ReaderRng::new(MemReader::new(v.as_slice().to_vec()));
         rng.fill_bytes(&mut w);
@@ -117,7 +117,7 @@ fn test_reader_rng_fill_bytes() {
     #[should_fail]
     fn test_reader_rng_insufficient_bytes() {
         let mut rng = ReaderRng::new(MemReader::new(vec!()));
-        let mut v = [0u8, .. 3];
+        let mut v = [0u8; 3];
         rng.fill_bytes(&mut v);
     }
 }
index 2feea7fa0a4382df63156ec8a48880fd160c86dc..4dbe878277da3d8efc2bc93495807954298773e6 100644 (file)
@@ -82,7 +82,7 @@ pub enum _Unwind_Reason_Code {
 pub struct _Unwind_Exception {
     pub exception_class: _Unwind_Exception_Class,
     pub exception_cleanup: _Unwind_Exception_Cleanup_Fn,
-    pub private: [_Unwind_Word, ..unwinder_private_data_size],
+    pub private: [_Unwind_Wordunwinder_private_data_size],
 }
 
 pub enum _Unwind_Context {}
index c273c52daccadbb5551cbea9a79d6955685271de..e0c512706e6a96b5fcdd5260748606cabd7ccecc 100644 (file)
@@ -83,7 +83,7 @@ struct Exception {
 //
 // For more information, see below.
 const MAX_CALLBACKS: uint = 16;
-static CALLBACKS: [atomic::AtomicUint, ..MAX_CALLBACKS] =
+static CALLBACKS: [atomic::AtomicUintMAX_CALLBACKS] =
         [atomic::INIT_ATOMIC_UINT, atomic::INIT_ATOMIC_UINT,
          atomic::INIT_ATOMIC_UINT, atomic::INIT_ATOMIC_UINT,
          atomic::INIT_ATOMIC_UINT, atomic::INIT_ATOMIC_UINT,
@@ -168,7 +168,7 @@ fn rust_panic(cause: Box<Any + Send>) -> ! {
             uwe: uw::_Unwind_Exception {
                 exception_class: rust_exception_class(),
                 exception_cleanup: exception_cleanup,
-                private: [0, ..uw::unwinder_private_data_size],
+                private: [0uw::unwinder_private_data_size],
             },
             cause: Some(cause),
         };
index 87ec20fbef872268df84480ea187a18b70229fc3..259c15b5f06347cbb93792023ecfe4e10afc0b17 100644 (file)
@@ -310,7 +310,7 @@ pub fn get_address_name(addr: IpAddr) -> Result<String, IoError> {
     let mut storage: libc::sockaddr_storage = unsafe { mem::zeroed() };
     let len = addr_to_sockaddr(addr, &mut storage);
 
-    let mut hostbuf = [0 as c_char, ..NI_MAXHOST];
+    let mut hostbuf = [0 as c_charNI_MAXHOST];
 
     let res = unsafe {
         getnameinfo(&storage as *const _ as *const libc::sockaddr, len,
index 417f1bf76028160c35e27f95bb9922f2c452a527..1bb8ed78177dc8e8735cef77dc5db511a3b2412f 100644 (file)
@@ -94,7 +94,7 @@ mod select {
 
     #[repr(C)]
     pub struct fd_set {
-        fds_bits: [i32, ..(FD_SETSIZE / 32)]
+        fds_bits: [i32(FD_SETSIZE / 32)]
     }
 
     pub fn fd_set(set: &mut fd_set, fd: i32) {
@@ -115,7 +115,7 @@ mod select {
     #[repr(C)]
     pub struct fd_set {
         // FIXME: shouldn't this be a c_ulong?
-        fds_bits: [libc::uintptr_t, ..(FD_SETSIZE / uint::BITS)]
+        fds_bits: [libc::uintptr_t(FD_SETSIZE / uint::BITS)]
     }
 
     pub fn fd_set(set: &mut fd_set, fd: i32) {
index 624d61cd41ff5f56cb92fe73bf89824bdee1b091..595191db3b2829b91910524ad23961896a79e4cf 100644 (file)
@@ -100,7 +100,7 @@ fn __xpg_strerror_r(errnum: c_int,
         }
     }
 
-    let mut buf = [0 as c_char, ..TMPBUF_SZ];
+    let mut buf = [0 as c_charTMPBUF_SZ];
 
     let p = buf.as_mut_ptr();
     unsafe {
@@ -124,7 +124,7 @@ pub unsafe fn pipe() -> IoResult<(FileDesc, FileDesc)> {
 pub fn getcwd() -> IoResult<Path> {
     use c_str::CString;
 
-    let mut buf = [0 as c_char, ..BUF_BYTES];
+    let mut buf = [0 as c_charBUF_BYTES];
     unsafe {
         if libc::getcwd(buf.as_mut_ptr(), buf.len() as libc::size_t).is_null() {
             Err(IoError::last_error())
index 8b62def62b61b5a26288cbba73ec9b062e7f30a4..77c5582d8a4ee8944e44686fc2afa886d83bb1e0 100644 (file)
@@ -86,30 +86,30 @@ mod os {
     #[repr(C)]
     pub struct pthread_mutex_t {
         __sig: libc::c_long,
-        __opaque: [u8, ..__PTHREAD_MUTEX_SIZE__],
+        __opaque: [u8__PTHREAD_MUTEX_SIZE__],
     }
     #[repr(C)]
     pub struct pthread_cond_t {
         __sig: libc::c_long,
-        __opaque: [u8, ..__PTHREAD_COND_SIZE__],
+        __opaque: [u8__PTHREAD_COND_SIZE__],
     }
     #[repr(C)]
     pub struct pthread_rwlock_t {
         __sig: libc::c_long,
-        __opaque: [u8, ..__PTHREAD_RWLOCK_SIZE__],
+        __opaque: [u8__PTHREAD_RWLOCK_SIZE__],
     }
 
     pub const PTHREAD_MUTEX_INITIALIZER: pthread_mutex_t = pthread_mutex_t {
         __sig: _PTHREAD_MUTEX_SIG_INIT,
-        __opaque: [0, ..__PTHREAD_MUTEX_SIZE__],
+        __opaque: [0__PTHREAD_MUTEX_SIZE__],
     };
     pub const PTHREAD_COND_INITIALIZER: pthread_cond_t = pthread_cond_t {
         __sig: _PTHREAD_COND_SIG_INIT,
-        __opaque: [0, ..__PTHREAD_COND_SIZE__],
+        __opaque: [0__PTHREAD_COND_SIZE__],
     };
     pub const PTHREAD_RWLOCK_INITIALIZER: pthread_rwlock_t = pthread_rwlock_t {
         __sig: _PTHREAD_RWLOCK_SIG_INIT,
-        __opaque: [0, ..__PTHREAD_RWLOCK_SIZE__],
+        __opaque: [0__PTHREAD_RWLOCK_SIZE__],
     };
 }
 
@@ -145,30 +145,30 @@ mod os {
     #[repr(C)]
     pub struct pthread_mutex_t {
         __align: libc::c_longlong,
-        size: [u8, ..__SIZEOF_PTHREAD_MUTEX_T],
+        size: [u8__SIZEOF_PTHREAD_MUTEX_T],
     }
     #[repr(C)]
     pub struct pthread_cond_t {
         __align: libc::c_longlong,
-        size: [u8, ..__SIZEOF_PTHREAD_COND_T],
+        size: [u8__SIZEOF_PTHREAD_COND_T],
     }
     #[repr(C)]
     pub struct pthread_rwlock_t {
         __align: libc::c_longlong,
-        size: [u8, ..__SIZEOF_PTHREAD_RWLOCK_T],
+        size: [u8__SIZEOF_PTHREAD_RWLOCK_T],
     }
 
     pub const PTHREAD_MUTEX_INITIALIZER: pthread_mutex_t = pthread_mutex_t {
         __align: 0,
-        size: [0, ..__SIZEOF_PTHREAD_MUTEX_T],
+        size: [0__SIZEOF_PTHREAD_MUTEX_T],
     };
     pub const PTHREAD_COND_INITIALIZER: pthread_cond_t = pthread_cond_t {
         __align: 0,
-        size: [0, ..__SIZEOF_PTHREAD_COND_T],
+        size: [0__SIZEOF_PTHREAD_COND_T],
     };
     pub const PTHREAD_RWLOCK_INITIALIZER: pthread_rwlock_t = pthread_rwlock_t {
         __align: 0,
-        size: [0, ..__SIZEOF_PTHREAD_RWLOCK_T],
+        size: [0__SIZEOF_PTHREAD_RWLOCK_T],
     };
 }
 #[cfg(target_os = "android")]
index 4f45831cb3af4756a53c63b74b2a3dd3e90d22a9..319a458087b9b51f949c997cf08c101ca55b662f 100644 (file)
@@ -83,7 +83,7 @@ struct SYMBOL_INFO {
     // note that windows has this as 1, but it basically just means that
     // the name is inline at the end of the struct. For us, we just bump
     // the struct size up to MAX_SYM_NAME.
-    Name: [libc::c_char, ..MAX_SYM_NAME],
+    Name: [libc::c_charMAX_SYM_NAME],
 }
 
 
@@ -162,7 +162,7 @@ pub struct CONTEXT {
         EFlags: libc::DWORD,
         Esp: libc::DWORD,
         SegSs: libc::DWORD,
-        ExtendedRegisters: [u8, ..MAXIMUM_SUPPORTED_EXTENSION],
+        ExtendedRegisters: [u8MAXIMUM_SUPPORTED_EXTENSION],
     }
 
     #[repr(C)]
@@ -245,7 +245,7 @@ pub struct CONTEXT {
 
         FltSave: FLOATING_SAVE_AREA,
 
-        VectorRegister: [M128A, .. 26],
+        VectorRegister: [M128A; 26],
         VectorControl: DWORDLONG,
 
         DebugControl: DWORDLONG,
index 06259d61fcb8413bfa24b78e6cd36ed7352b7a87..6cccefbe89064dd20e0cf7133f88509c92541ca0 100644 (file)
@@ -43,8 +43,8 @@
 pub struct WSADATA {
     pub wVersion: libc::WORD,
     pub wHighVersion: libc::WORD,
-    pub szDescription: [u8, ..WSADESCRIPTION_LEN + 1],
-    pub szSystemStatus: [u8, ..WSASYS_STATUS_LEN + 1],
+    pub szDescription: [u8WSADESCRIPTION_LEN + 1],
+    pub szSystemStatus: [u8WSASYS_STATUS_LEN + 1],
     pub iMaxSockets: u16,
     pub iMaxUdpDg: u16,
     pub lpVendorInfo: *mut u8,
@@ -57,8 +57,8 @@ pub struct WSADATA {
     pub iMaxSockets: u16,
     pub iMaxUdpDg: u16,
     pub lpVendorInfo: *mut u8,
-    pub szDescription: [u8, ..WSADESCRIPTION_LEN + 1],
-    pub szSystemStatus: [u8, ..WSASYS_STATUS_LEN + 1],
+    pub szDescription: [u8WSADESCRIPTION_LEN + 1],
+    pub szSystemStatus: [u8WSASYS_STATUS_LEN + 1],
 }
 
 pub type LPWSADATA = *mut WSADATA;
@@ -66,7 +66,7 @@ pub struct WSADATA {
 #[repr(C)]
 pub struct WSANETWORKEVENTS {
     pub lNetworkEvents: libc::c_long,
-    pub iErrorCode: [libc::c_int, ..FD_MAX_EVENTS],
+    pub iErrorCode: [libc::c_intFD_MAX_EVENTS],
 }
 
 pub type LPWSANETWORKEVENTS = *mut WSANETWORKEVENTS;
@@ -76,7 +76,7 @@ pub struct WSANETWORKEVENTS {
 #[repr(C)]
 pub struct fd_set {
     fd_count: libc::c_uint,
-    fd_array: [libc::SOCKET, ..FD_SETSIZE],
+    fd_array: [libc::SOCKETFD_SETSIZE],
 }
 
 pub fn fd_set(set: &mut fd_set, s: libc::SOCKET) {
index 127d4f996220057f7f3b666c9ce5efb6e364cd75..09003f87ff0c143d655a7eb0da756caf170fc195 100644 (file)
@@ -80,7 +80,7 @@ fn FormatMessageW(flags: DWORD,
     // MAKELANGID(LANG_SYSTEM_DEFAULT, SUBLANG_SYS_DEFAULT)
     let langId = 0x0800 as DWORD;
 
-    let mut buf = [0 as WCHAR, ..TMPBUF_SZ];
+    let mut buf = [0 as WCHARTMPBUF_SZ];
 
     unsafe {
         let res = FormatMessageW(FORMAT_MESSAGE_FROM_SYSTEM |
@@ -164,7 +164,7 @@ pub fn getcwd() -> IoResult<Path> {
     use libc::GetCurrentDirectoryW;
     use io::OtherIoError;
 
-    let mut buf = [0 as u16, ..BUF_BYTES];
+    let mut buf = [0 as u16BUF_BYTES];
     unsafe {
         if libc::GetCurrentDirectoryW(buf.len() as DWORD, buf.as_mut_ptr()) == 0 as DWORD {
             return Err(IoError::last_error());
index bdf2e0bccb1a07695e27b6ccb86d601854a20d96..e8b447022cbf4f0b0134bc857c5fd3ca4290d76f 100644 (file)
@@ -90,7 +90,7 @@ pub struct EXCEPTION_RECORD {
     pub ExceptionRecord: *mut EXCEPTION_RECORD,
     pub ExceptionAddress: LPVOID,
     pub NumberParameters: DWORD,
-    pub ExceptionInformation: [LPVOID, ..EXCEPTION_MAXIMUM_PARAMETERS]
+    pub ExceptionInformation: [LPVOIDEXCEPTION_MAXIMUM_PARAMETERS]
 }
 
 pub struct EXCEPTION_POINTERS {
index 90fc28014e64f83101d1827d5f5547e60d1f1511..720a907fe77f0cb4971bbfc92c9232741bd6bbf0 100644 (file)
@@ -119,6 +119,6 @@ pub fn expand_build_diagnostic_array<'cx>(ecx: &'cx mut ExtCtxt,
         });
 
     MacItems::new(vec![quote_item!(ecx,
-        pub static $name: [(&'static str, &'static str), ..$count] = $expr;
+        pub static $name: [(&'static str, &'static str)$count] = $expr;
     ).unwrap()].into_iter())
 }
index 33178fe81054227a0a4c257faf94434fe555e1ba..3c01a7756a6b9656fbabb3e67a38e7272f778721 100644 (file)
@@ -11,5 +11,5 @@
 // Test that the old fixed length array syntax is a parsing error.
 
 fn main() {
-    let _x: [int, ..3] = [0i, 1, 2]; //~ ERROR 
+    let _x: [int, ..3] = [0i, 1, 2]; //~ ERROR
 }
index 2e0f2a174c606575242e7b3fc4bad62cb40152b7..672d8a30fc56c808c2636f11ad688d9f8de0f63c 100644 (file)
@@ -9,5 +9,5 @@
 // except according to those terms.
 
 fn main() {
-    let x: [int 3]; //~ ERROR expected one of `(`, `+`, `,`, `::`, `;`, or `]`, found `3`
+    let x: [int 3]; //~ ERROR expected one of `(`, `+`, `::`, `;`, or `]`, found `3`
 }
index 81f9ed991ebe5629437163a8b79006cd6f6bb7ca..3224edb381cccbf2d1c4c0dbecc230308478eca4 100644 (file)
 #[cfg(target_word_size = "64")]
 fn main() {
     let n = 0u;
-    let a = box [&n,..0xF000000000000000u];
+    let a = box [&n0xF000000000000000u];
     println!("{}", a[0xFFFFFFu]);
 }
 
 #[cfg(target_word_size = "32")]
 fn main() {
     let n = 0u;
-    let a = box [&n,..0xFFFFFFFFu];
+    let a = box [&n0xFFFFFFFFu];
     println!("{}", a[0xFFFFFFu]);
 }
index d0ff116b42fe1b829856b3142a757ce7ae211051..c2bd810abad2537858a7a202cc1fed87fff22b73 100644 (file)
@@ -11,5 +11,5 @@
 // Trying to create a fixed-length vector with a negative size
 
 fn main() {
-      let _x = [0,..-1]; //~ ERROR found negative integer
+      let _x = [0-1]; //~ ERROR found negative integer
 }
index 0a8420c19c33f2cbc0b3199d610ac5482e8c8476..6537e3ddd27d0c11caa7f475171007181a8ef128 100644 (file)
@@ -8,4 +8,4 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-type v = [int * 3]; //~ ERROR expected one of `(`, `+`, `,`, `::`, `;`, or `]`, found `*`
+type v = [int * 3]; //~ ERROR expected one of `(`, `+`, `::`, `;`, or `]`, found `*`
index 9c6056bd72a1c1c8f4c04119b5b966618c2c9b5a..efde1f1b24d617efe673cf8bebc9bb6a2ea4be6b 100644 (file)
@@ -10,4 +10,4 @@
 
 type v = [mut int];
     //~^  ERROR expected identifier, found keyword `mut`
-    //~^^ ERROR expected one of `(`, `+`, `,`, `::`, `;`, or `]`, found `int`
+    //~^^ ERROR expected one of `(`, `+`, `::`, `;`, or `]`, found `int`
index 84c592defaa26cbc5cad3216e91b73a6e483adca..b481e109e1a3d4e30e7eda1ec7d79a5a4a79a0ec 100644 (file)
@@ -20,29 +20,29 @@ pub fn bar() {
     const FOO: uint = 5u - 4u;
     let _: [(); FOO] = [()];
 
-    let _ : [(), ..1u] = [()];
+    let _ : [()1u] = [()];
 
-    let _ = &([1i,2,3]) as *const _ as *const [int, ..3u];
+    let _ = &([1i,2,3]) as *const _ as *const [int3u];
 
     format!("test");
 }
 
-pub type Foo = [int, ..3u];
+pub type Foo = [int3u];
 
 pub struct Bar {
-    pub x: [int, ..3u]
+    pub x: [int3u]
 }
 
-pub struct TupleBar([int, ..4u]);
+pub struct TupleBar([int4u]);
 
 pub enum Baz {
-    BazVariant([int, ..5u])
+    BazVariant([int5u])
 }
 
 pub fn id<T>(x: T) -> T { x }
 
 pub fn use_id() {
-    let _ = id::<[int, ..3u]>([1,2,3]);
+    let _ = id::<[int3u]>([1,2,3]);
 }
 
 
index d9d3e3202609724cf92367ab344a84fc3c532cc7..5f7770e97a9cf99258c19f8752b4af5d248fcb0e 100644 (file)
@@ -9,7 +9,7 @@
 // except according to those terms.
 
 pub fn main() {
-    let x = [1i,..100];
+    let x = [1i100];
     let mut y = 0i;
     for i in x.iter() {
         if y > 10 {
index c6c2d42392749cf3ce1dffa1048af036f4761229..d8c6dd6a93dae97d8e745e9e8fc006f04f3c6d22 100644 (file)
@@ -9,7 +9,7 @@
 // except according to those terms.
 
 pub fn main() {
-    let x = [1i,..100];
+    let x = [1i100];
     let mut y = 0i;
     for (n,i) in x.iter().enumerate() {
         if n < 10 {
index f4d38dfcfc329e3373a829656a2a4b430c1df2d3..20ea9c440a1fc49be8878406bf1cf52f420b60ba 100644 (file)
@@ -9,8 +9,8 @@
 // except according to those terms.
 
 pub fn main() {
-    let x = [1i,..100];
-    let y = [2i,..100];
+    let x = [1i100];
+    let y = [2i100];
     let mut p = 0i;
     let mut q = 0i;
     for i in x.iter() {
index 684a9b81fb256f72efa7d5009c90fac1d6e84495..0ac642cc449af763ef05bfb14899b7c2ac8ab626 100644 (file)
@@ -9,7 +9,7 @@
 // except according to those terms.
 
 pub fn main() {
-    let x = [1i,..100];
+    let x = [1i100];
     let mut y = 0i;
     for i in x.iter() {
         y += *i
index e070757eaf4ea1b2f04a40d7bb65db50809b5680..70a41f773a3e0a2c4cdd45ebfe12087525b6e630 100644 (file)
@@ -13,6 +13,6 @@
 
 pub fn main() {
     unsafe {
-        ::std::mem::transmute::<[int,..1],int>([1])
+        ::std::mem::transmute::<[int1],int>([1])
     };
 }