Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 17 lines (14 sloc) 0.35 kb
267ab11 @nikomatsakis use + mode for (almost) everything when not using legacy modes
nikomatsakis authored
1 fn main(++args: ~[~str]) {
92743dc @msullivan Move the world over to using the new style string literals and types.…
msullivan authored
2 let args = if os::getenv(~"RUST_BENCH").is_some() {
3 ~[~"", ~"10000000"]
6e00852 @brson core: Make uint::to_str faster
brson authored
4 } else if args.len() <= 1u {
92743dc @msullivan Move the world over to using the new style string literals and types.…
msullivan authored
5 ~[~"", ~"100000"]
6e00852 @brson core: Make uint::to_str faster
brson authored
6 } else {
7 args
8 };
9
10 let n = uint::from_str(args[1]).get();
11
d1fc2b5 @brson Convert to new closure syntax
brson authored
12 for uint::range(0u, n) |i| {
6e00852 @brson core: Make uint::to_str faster
brson authored
13 let x = uint::to_str(i, 10u);
14 log(debug, x);
15 }
16 }
Something went wrong with that request. Please try again.