Skip to content

Commit f0eae8f

Browse files
committed
Convert field terminators to commas. Stop parsing semis.
1 parent 3078830 commit f0eae8f

File tree

91 files changed

+284
-284
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

91 files changed

+284
-284
lines changed

src/libcore/future.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ export future_pipe;
3333

3434
#[doc = "The future type"]
3535
struct Future<A> {
36-
/*priv*/ mut state: FutureState<A>;
36+
/*priv*/ mut state: FutureState<A>,
3737
}
3838

3939
priv enum FutureState<A> {

src/libcore/hash.rs

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -176,15 +176,15 @@ fn default_state() -> State {
176176
}
177177

178178
struct SipState {
179-
k0: u64;
180-
k1: u64;
181-
mut length: uint; // how many bytes we've processed
182-
mut v0: u64; // hash state
183-
mut v1: u64;
184-
mut v2: u64;
185-
mut v3: u64;
186-
tail: [mut u8]/8; // unprocessed bytes
187-
mut ntail: uint; // how many bytes in tail are valid
179+
k0: u64,
180+
k1: u64,
181+
mut length: uint, // how many bytes we've processed
182+
mut v0: u64, // hash state
183+
mut v1: u64,
184+
mut v2: u64,
185+
mut v3: u64,
186+
tail: [mut u8]/8, // unprocessed bytes
187+
mut ntail: uint, // how many bytes in tail are valid
188188
}
189189

190190
#[inline(always)]

src/libcore/managed.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ export Managed;
2020
enum Mode { ReadOnly, Mutable, Immutable }
2121

2222
struct Data<T> {
23-
priv mut value: T;
24-
priv mut mode: Mode;
23+
priv mut value: T,
24+
priv mut mode: Mode
2525
}
2626

2727
type Managed<T> = @Data<T>;

src/libcore/path.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,15 @@
55
use cmp::Eq;
66

77
struct WindowsPath {
8-
host: Option<~str>;
9-
device: Option<~str>;
10-
is_absolute: bool;
11-
components: ~[~str];
8+
host: Option<~str>,
9+
device: Option<~str>,
10+
is_absolute: bool,
11+
components: ~[~str],
1212
}
1313

1414
struct PosixPath {
15-
is_absolute: bool;
16-
components: ~[~str];
15+
is_absolute: bool,
16+
components: ~[~str],
1717
}
1818

1919
trait GenericPath {

src/libcore/pipes.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -465,7 +465,7 @@ fn try_recv<T: send, Tbuffer: send>(+p: RecvPacketBuffered<T, Tbuffer>)
465465
let p = unsafe { &*p_ };
466466

467467
struct DropState {
468-
p: &PacketHeader;
468+
p: &PacketHeader,
469469

470470
drop {
471471
if task::failing() {

src/libcore/send_map.rs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -30,16 +30,16 @@ mod linear {
3030

3131
const initial_capacity: uint = 32u; // 2^5
3232
struct Bucket<K:Eq Hash,V> {
33-
hash: uint;
34-
key: K;
35-
value: V;
33+
hash: uint,
34+
key: K,
35+
value: V,
3636
}
3737
struct LinearMap<K:Eq Hash,V> {
38-
k0: u64;
39-
k1: u64;
40-
resize_at: uint;
41-
size: uint;
42-
buckets: ~[Option<Bucket<K,V>>];
38+
k0: u64,
39+
k1: u64,
40+
resize_at: uint,
41+
size: uint,
42+
buckets: ~[Option<Bucket<K,V>>],
4343
}
4444

4545
// FIXME(#3148) -- we could rewrite found_entry

src/libcore/sys.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ enum TypeDesc = {
2828

2929
/// The representation of a Rust closure
3030
struct Closure {
31-
code: *();
32-
env: *();
31+
code: *(),
32+
env: *(),
3333
}
3434

3535
#[abi = "cdecl"]

src/libcore/unsafe.rs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -86,15 +86,15 @@ unsafe fn copy_lifetime<S,T>(_ptr: &a/S, ptr: &T) -> &a/T {
8686
type UnwrapProto = ~mut Option<(pipes::ChanOne<()>, pipes::PortOne<bool>)>;
8787

8888
struct ArcData<T> {
89-
mut count: libc::intptr_t;
90-
mut unwrapper: libc::uintptr_t; // either a UnwrapProto or 0
89+
mut count: libc::intptr_t,
90+
mut unwrapper: libc::uintptr_t, // either a UnwrapProto or 0
9191
// FIXME(#3224) should be able to make this non-option to save memory, and
9292
// in unwrap() use "let ~ArcData { data: result, _ } = thing" to unwrap it
93-
mut data: Option<T>;
93+
mut data: Option<T>,
9494
}
9595

9696
struct ArcDestruct<T> {
97-
mut data: *libc::c_void;
97+
mut data: *libc::c_void,
9898
drop unsafe {
9999
if self.data.is_null() {
100100
return; // Happens when destructing an unwrapper's handle.
@@ -140,8 +140,8 @@ fn ArcDestruct<T>(data: *libc::c_void) -> ArcDestruct<T> {
140140
unsafe fn unwrap_shared_mutable_state<T: send>(+rc: SharedMutableState<T>)
141141
-> T {
142142
struct DeathThroes<T> {
143-
mut ptr: Option<~ArcData<T>>;
144-
mut response: Option<pipes::ChanOne<bool>>;
143+
mut ptr: Option<~ArcData<T>>,
144+
mut response: Option<pipes::ChanOne<bool>>,
145145
drop unsafe {
146146
let response = option::swap_unwrap(&mut self.response);
147147
// In case we get killed early, we need to tell the person who
@@ -312,11 +312,11 @@ impl LittleLock {
312312
}
313313
}
314314

315-
struct ExData<T: send> { lock: LittleLock; mut failed: bool; mut data: T; }
315+
struct ExData<T: send> { lock: LittleLock, mut failed: bool, mut data: T, }
316316
/**
317317
* An arc over mutable data that is protected by a lock. For library use only.
318318
*/
319-
struct Exclusive<T: send> { x: SharedMutableState<ExData<T>>; }
319+
struct Exclusive<T: send> { x: SharedMutableState<ExData<T>> }
320320

321321
fn exclusive<T:send >(+user_data: T) -> Exclusive<T> {
322322
let data = ExData {

src/libcore/util.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ fn replace<T>(dest: &mut T, +src: T) -> T {
5454

5555
/// A non-copyable dummy type.
5656
struct NonCopyable {
57-
i: ();
57+
i: (),
5858
drop { }
5959
}
6060

src/libstd/arc.rs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ export RWARC, rw_arc_with_condvars, RWWriteMode, RWReadMode;
1919
export unwrap_rw_arc;
2020

2121
/// As sync::condvar, a mechanism for unlock-and-descheduling and signalling.
22-
struct Condvar { is_mutex: bool; failed: &mut bool; cond: &sync::Condvar; }
22+
struct Condvar { is_mutex: bool, failed: &mut bool, cond: &sync::Condvar }
2323

2424
impl &Condvar {
2525
/// Atomically exit the associated ARC and block until a signal is sent.
@@ -69,7 +69,7 @@ impl &Condvar {
6969
****************************************************************************/
7070

7171
/// An atomically reference counted wrapper for shared immutable state.
72-
struct ARC<T: const send> { x: SharedMutableState<T>; }
72+
struct ARC<T: const send> { x: SharedMutableState<T> }
7373

7474
/// Create an atomically reference counted wrapper.
7575
fn ARC<T: const send>(+data: T) -> ARC<T> {
@@ -114,9 +114,9 @@ fn unwrap<T: const send>(+rc: ARC<T>) -> T {
114114
****************************************************************************/
115115

116116
#[doc(hidden)]
117-
struct MutexARCInner<T: send> { lock: Mutex; failed: bool; data: T; }
117+
struct MutexARCInner<T: send> { lock: Mutex, failed: bool, data: T }
118118
/// An ARC with mutable data protected by a blocking mutex.
119-
struct MutexARC<T: send> { x: SharedMutableState<MutexARCInner<T>>; }
119+
struct MutexARC<T: send> { x: SharedMutableState<MutexARCInner<T>> }
120120

121121
/// Create a mutex-protected ARC with the supplied data.
122122
fn MutexARC<T: send>(+user_data: T) -> MutexARC<T> {
@@ -222,7 +222,7 @@ fn check_poison(is_mutex: bool, failed: bool) {
222222
223223
#[doc(hidden)]
224224
struct PoisonOnFail {
225-
failed: &mut bool;
225+
failed: &mut bool,
226226
drop {
227227
/* assert !*self.failed; -- might be false in case of cond.wait() */
228228
if task::failing() { *self.failed = true; }
@@ -240,16 +240,16 @@ fn PoisonOnFail(failed: &r/mut bool) -> PoisonOnFail/&r {
240240
****************************************************************************/
241241
242242
#[doc(hidden)]
243-
struct RWARCInner<T: const send> { lock: RWlock; failed: bool; data: T; }
243+
struct RWARCInner<T: const send> { lock: RWlock, failed: bool, data: T }
244244
/**
245245
* A dual-mode ARC protected by a reader-writer lock. The data can be accessed
246246
* mutably or immutably, and immutably-accessing tasks may run concurrently.
247247
*
248248
* Unlike mutex_arcs, rw_arcs are safe, because they cannot be nested.
249249
*/
250250
struct RWARC<T: const send> {
251-
x: SharedMutableState<RWARCInner<T>>;
252-
mut cant_nest: ();
251+
x: SharedMutableState<RWARCInner<T>>,
252+
mut cant_nest: ()
253253
}
254254
255255
/// Create a reader/writer ARC with the supplied data.

src/libstd/arena.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,9 @@ struct Arena {
5151
// The head is seperated out from the list as a unbenchmarked
5252
// microoptimization, to avoid needing to case on the list to
5353
// access the head.
54-
priv mut head: Chunk;
55-
priv mut pod_head: Chunk;
56-
priv mut chunks: @List<Chunk>;
54+
priv mut head: Chunk,
55+
priv mut pod_head: Chunk,
56+
priv mut chunks: @List<Chunk>,
5757
drop {
5858
unsafe {
5959
destroy_chunk(self.head);

src/libstd/cell.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
/// Similar to a mutable option type, but friendlier.
66
77
struct Cell<T> {
8-
mut value: Option<T>;
8+
mut value: Option<T>
99
}
1010

1111
/// Creates a new full cell with the given value.

src/libstd/comm.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ export DuplexStream;
1414

1515
/// An extension of `pipes::stream` that allows both sending and receiving.
1616
struct DuplexStream<T: send, U: send> : Channel<T>, Recv<U>, Selectable {
17-
priv chan: Chan<T>;
18-
priv port: Port <U>;
17+
priv chan: Chan<T>,
18+
priv port: Port <U>,
1919

2020
fn send(+x: T) {
2121
self.chan.send(x)

src/libstd/map.rs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -113,17 +113,17 @@ mod chained {
113113
const initial_capacity: uint = 32u; // 2^5
114114

115115
struct entry<K, V> {
116-
hash: uint;
117-
key: K;
118-
value: V;
119-
mut next: Option<@entry<K, V>>;
116+
hash: uint,
117+
key: K,
118+
value: V,
119+
mut next: Option<@entry<K, V>>
120120
}
121121

122122
struct hashmap_<K, V> {
123-
mut count: uint;
124-
mut chains: ~[mut Option<@entry<K,V>>];
125-
hasher: hashfn<K>;
126-
eqer: eqfn<K>;
123+
mut count: uint,
124+
mut chains: ~[mut Option<@entry<K,V>>],
125+
hasher: hashfn<K>,
126+
eqer: eqfn<K>
127127
}
128128

129129
type t<K, V> = @hashmap_<K, V>;

0 commit comments

Comments
 (0)