Skip to content

Commit b5b7ff3

Browse files
committed
---
yaml --- r: 92868 b: refs/heads/auto c: 870024a h: refs/heads/master v: v3
1 parent d9e4eb7 commit b5b7ff3

File tree

181 files changed

+1981
-3400
lines changed

Some content is hidden

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

181 files changed

+1981
-3400
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ refs/heads/try3: 9387340aab40a73e8424c48fd42f0c521a4875c0
1313
refs/tags/release-0.3.1: 495bae036dfe5ec6ceafd3312b4dca48741e845b
1414
refs/tags/release-0.4: e828ea2080499553b97dfe33b3f4d472b4562ad7
1515
refs/tags/release-0.5: 7e3bcfbf21278251ee936ad53e92e9b719702d73
16-
refs/heads/auto: 8ec03b37c05203026c02336639428146f1c4360e
16+
refs/heads/auto: 870024a16047341644e31d6ba7617162c205d204
1717
refs/heads/servo: af82457af293e2a842ba6b7759b70288da276167
1818
refs/tags/release-0.6: b4ebcfa1812664df5e142f0134a5faea3918544c
1919
refs/tags/0.1: b19db808c2793fe2976759b85a355c3ad8c8b336

branches/auto/.gitignore

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -75,10 +75,6 @@ src/.DS_Store
7575
/doc/latex
7676
/doc/std
7777
/doc/extra
78-
/doc/green
79-
/doc/native
80-
/doc/rustc
81-
/doc/syntax
8278
/nd/
8379
/llvm/
8480
version.md

branches/auto/.gitmodules

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
[submodule "src/llvm"]
22
path = src/llvm
3-
url = https://github.com/luqmana/llvm.git
3+
url = https://github.com/alexcrichton/llvm.git
44
branch = master
55
[submodule "src/libuv"]
66
path = src/libuv
77
url = https://github.com/alexcrichton/libuv.git
88
branch = master
99
[submodule "src/gyp"]
1010
path = src/gyp
11-
url = https://github.com/alexcrichton/gyp.git
11+
url = https://github.com/brson/gyp.git

branches/auto/doc/rust.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -610,12 +610,12 @@ the behavior of the compiler.
610610

611611
~~~~
612612
// Package ID
613-
#[ crate_id = "projx#2.5" ];
613+
#[ pkgid = "projx#2.5" ];
614614
615615
// Additional metadata attributes
616616
#[ desc = "Project X" ];
617617
#[ license = "BSD" ];
618-
#[ comment = "This is a comment on Project X." ];
618+
#[ author = "Jane Doe" ];
619619
620620
// Specify the output type
621621
#[ crate_type = "lib" ];
@@ -776,9 +776,9 @@ as the `ident` provided in the `extern_mod_decl`.
776776
The external crate is resolved to a specific `soname` at compile time, and a
777777
runtime linkage requirement to that `soname` is passed to the linker for
778778
loading at runtime. The `soname` is resolved at compile time by scanning the
779-
compiler's library path and matching the optional `crateid` provided as a string literal
780-
against the `crateid` attributes that were declared on the external crate when
781-
it was compiled. If no `crateid` is provided, a default `name` attribute is
779+
compiler's library path and matching the optional `pkgid` provided as a string literal
780+
against the `pkgid` attributes that were declared on the external crate when
781+
it was compiled. If no `pkgid` is provided, a default `name` attribute is
782782
assumed, equal to the `ident` given in the `extern_mod_decl`.
783783

784784
Four examples of `extern mod` declarations:
@@ -1729,7 +1729,7 @@ names are effectively reserved. Some significant attributes include:
17291729
* The `cfg` attribute, for conditional-compilation by build-configuration.
17301730
* The `lang` attribute, for custom definitions of traits and functions that are known to the Rust compiler (see [Language items](#language-items)).
17311731
* The `link` attribute, for describing linkage metadata for a extern blocks.
1732-
* The `crate_id` attribute, for describing the package ID of a crate.
1732+
* The `pkgid` attribute, for describing the package ID of a crate.
17331733
* The `test` attribute, for marking functions as unit tests.
17341734
* The `allow`, `warn`, `forbid`, and `deny` attributes, for
17351735
controlling lint checks (see [Lint check attributes](#lint-check-attributes)).
@@ -3792,7 +3792,7 @@ specified then log level 4 is assumed. Debug messages can be omitted
37923792
by passing `--cfg ndebug` to `rustc`.
37933793

37943794
As an example, to see all the logs generated by the compiler, you would set
3795-
`RUST_LOG` to `rustc`, which is the crate name (as specified in its `crate_id`
3795+
`RUST_LOG` to `rustc`, which is the crate name (as specified in its `pkgid`
37963796
[attribute](#attributes)). To narrow down the logs to just crate resolution,
37973797
you would set it to `rustc::metadata::creader`. To see just error logging
37983798
use `rustc=0`.

branches/auto/doc/rustdoc.md

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ comments":
1313
~~~
1414
// the "link" crate attribute is currently required for rustdoc, but normally
1515
// isn't needed.
16-
#[crate_id = "universe"];
16+
#[pkgid = "universe"];
1717
#[crate_type="lib"];
1818
1919
//! Tools for dealing with universes (this is a doc comment, and is shown on
@@ -132,10 +132,9 @@ specifiers that can be used to dictate how a code block is tested:
132132
~~~
133133

134134
Rustdoc also supplies some extra sugar for helping with some tedious
135-
documentation examples. If a line is prefixed with `# `, then the line
136-
will not show up in the HTML documentation, but it will be used when
137-
testing the code block (NB. the space after the `#` is required, so
138-
that one can still write things like `#[deriving(Eq)]`).
135+
documentation examples. If a line is prefixed with a `#` character, then the
136+
line will not show up in the HTML documentation, but it will be used when
137+
testing the code block.
139138

140139
~~~
141140
```rust

branches/auto/doc/rustpkg.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ then both `bar` and `bar/extras/baz` are valid package identifiers
9090
in the workspace `foo`.
9191

9292
Because rustpkg uses generic source file names as the main inputs, you will
93-
need to specify the package identifier in them using the `crate_id` attribute
93+
need to specify the package identifier in them using the `pkgid` attribute
9494
on the crate.
9595

9696
## Source files

branches/auto/doc/tutorial.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3071,7 +3071,7 @@ Therefore, if you plan to compile your crate as a library, you should annotate i
30713071
30723072
# #[crate_type = "lib"];
30733073
// Package ID
3074-
#[crate_id = "farm#2.5"];
3074+
#[pkgid = "farm#2.5"];
30753075
30763076
// ...
30773077
# fn farm() {}
@@ -3095,7 +3095,7 @@ or setting the crate type (library or executable) explicitly:
30953095
// ...
30963096
30973097
// This crate is a library ("bin" is the default)
3098-
#[crate_id = "farm#2.5"];
3098+
#[pkgid = "farm#2.5"];
30993099
#[crate_type = "lib"];
31003100
31013101
// Turn on a warning
@@ -3116,7 +3116,7 @@ We define two crates, and use one of them as a library in the other.
31163116

31173117
~~~~
31183118
// world.rs
3119-
#[crate_id = "world#0.42"];
3119+
#[pkgid = "world#0.42"];
31203120
# extern mod extra;
31213121
pub fn explore() -> &'static str { "world" }
31223122
# fn main() {}

branches/auto/mk/docs.mk

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
######################################################################
1414

1515
DOCS :=
16-
CDOCS :=
1716
DOCS_L10N :=
1817

1918
BASE_DOC_OPTS := --from=markdown --standalone --toc --number-sections
@@ -233,21 +232,8 @@ doc/$(1)/index.html: $$(RUSTDOC) $$(TLIB2_T_$(3)_H_$(3))/$(CFG_STDLIB_$(3))
233232
DOCS += doc/$(1)/index.html
234233
endef
235234

236-
define compiledoc
237-
doc/$(1)/index.html: $$(RUSTDOC) $$(TLIB2_T_$(3)_H_$(3))/$(CFG_STDLIB_$(3))
238-
@$$(call E, rustdoc: $$@)
239-
$(Q)$(RUSTDOC) --cfg stage2 $(2)
240-
241-
CDOCS += doc/$(1)/index.html
242-
endef
243-
244235
$(eval $(call libdoc,std,$(STDLIB_CRATE),$(CFG_BUILD)))
245236
$(eval $(call libdoc,extra,$(EXTRALIB_CRATE),$(CFG_BUILD)))
246-
$(eval $(call libdoc,native,$(LIBNATIVE_CRATE),$(CFG_BUILD)))
247-
$(eval $(call libdoc,green,$(LIBGREEN_CRATE),$(CFG_BUILD)))
248-
249-
$(eval $(call compiledoc,rustc,$(COMPILER_CRATE),$(CFG_BUILD)))
250-
$(eval $(call compiledoc,syntax,$(LIBSYNTAX_CRATE),$(CFG_BUILD)))
251237

252238

253239
ifdef CFG_DISABLE_DOCS
@@ -270,7 +256,6 @@ doc/version_info.html: version_info.html.template $(MKFILE_DEPS) \
270256
GENERATED += doc/version.md doc/version_info.html
271257

272258
docs: $(DOCS)
273-
compiler-docs: $(CDOCS)
274259

275260
docs-l10n: $(DOCS_L10N)
276261

branches/auto/src/etc/combine-tests.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ def scrub(b):
4545
"""
4646
// AUTO-GENERATED FILE: DO NOT EDIT
4747
#[crate_id=\"run_pass_stage2#0.1\"];
48-
#[crate_id=\"run_pass_stage2#0.1\"];
48+
#[pkgid=\"run_pass_stage2#0.1\"];
4949
#[feature(globs, macro_rules, struct_variant, managed_boxes)];
5050
#[allow(warnings)];
5151
"""

branches/auto/src/etc/vim/syntax/rust.vim

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ syn keyword rustTrait Default
7878
syn keyword rustTrait Hash
7979
syn keyword rustTrait FromStr
8080
syn keyword rustTrait FromIterator Extendable
81-
syn keyword rustTrait Iterator DoubleEndedIterator RandomAccessIterator CloneableIterator
81+
syn keyword rustTrait Iterator DoubleEndedIterator RandomAccessIterator ClonableIterator
8282
syn keyword rustTrait OrdIterator MutableDoubleEndedIterator ExactSize
8383
syn keyword rustTrait Times
8484

branches/auto/src/gyp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
Subproject commit 1e46da1000bc29679ab4cebf3c1034cb7d6f4487
1+
Subproject commit f407f09c94e00d2d570e8e42114e3f6848b2deb2

branches/auto/src/libextra/enum_set.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
//! This module defines a container which uses an efficient bit mask
1414
//! representation to hold C-like enum variants.
1515
16-
#[deriving(Clone, Eq, IterBytes, ToStr, Encodable, Decodable)]
16+
#[deriving(Clone, Eq, IterBytes, ToStr)]
1717
/// A specialized Set implementation to use enum types.
1818
pub struct EnumSet<E> {
1919
// We must maintain the invariant that no bits are set

branches/auto/src/libextra/getopts.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
//!
3232
//! ~~~{.rust}
3333
//! extern mod extra;
34-
//! use extra::getopts::{optopt,optflag,getopts,Opt};
34+
//! use extra::getopts::*;
3535
//! use std::os;
3636
//!
3737
//! fn do_work(inp: &str, out: Option<~str>) {

branches/auto/src/libextra/num/rational.rs

Lines changed: 1 addition & 60 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
use std::cmp;
1515
use std::from_str::FromStr;
1616
use std::num::{Zero,One,ToStrRadix,FromStrRadix,Round};
17-
use super::bigint::{BigInt, BigUint, Sign, Plus, Minus};
17+
use super::bigint::BigInt;
1818

1919
/// Represents the ratio between 2 numbers.
2020
#[deriving(Clone)]
@@ -107,27 +107,6 @@ impl<T: Clone + Integer + Ord>
107107
}
108108
}
109109

110-
impl Ratio<BigInt> {
111-
/// Converts a float into a rational number
112-
pub fn from_float<T: Float>(f: T) -> Option<BigRational> {
113-
if !f.is_finite() {
114-
return None;
115-
}
116-
let (mantissa, exponent, sign) = f.integer_decode();
117-
let bigint_sign: Sign = if sign == 1 { Plus } else { Minus };
118-
if exponent < 0 {
119-
let one: BigInt = One::one();
120-
let denom: BigInt = one << ((-exponent) as uint);
121-
let numer: BigUint = FromPrimitive::from_u64(mantissa).unwrap();
122-
Some(Ratio::new(BigInt::from_biguint(bigint_sign, numer), denom))
123-
} else {
124-
let mut numer: BigUint = FromPrimitive::from_u64(mantissa).unwrap();
125-
numer = numer << (exponent as uint);
126-
Some(Ratio::from_integer(BigInt::from_biguint(bigint_sign, numer)))
127-
}
128-
}
129-
}
130-
131110
/* Comparisons */
132111

133112
// comparing a/b and c/d is the same as comparing a*d and b*c, so we
@@ -642,42 +621,4 @@ mod test {
642621
test(s);
643622
}
644623
}
645-
646-
#[test]
647-
fn test_from_float() {
648-
fn test<T: Float>(given: T, (numer, denom): (&str, &str)) {
649-
let ratio: BigRational = Ratio::from_float(given).unwrap();
650-
assert_eq!(ratio, Ratio::new(
651-
FromStr::from_str(numer).unwrap(),
652-
FromStr::from_str(denom).unwrap()));
653-
}
654-
655-
// f32
656-
test(3.14159265359f32, ("13176795", "4194304"));
657-
test(2f32.pow(&100.), ("1267650600228229401496703205376", "1"));
658-
test(-2f32.pow(&100.), ("-1267650600228229401496703205376", "1"));
659-
test(1.0 / 2f32.pow(&100.), ("1", "1267650600228229401496703205376"));
660-
test(684729.48391f32, ("1369459", "2"));
661-
test(-8573.5918555f32, ("-4389679", "512"));
662-
663-
// f64
664-
test(3.14159265359f64, ("3537118876014453", "1125899906842624"));
665-
test(2f64.pow(&100.), ("1267650600228229401496703205376", "1"));
666-
test(-2f64.pow(&100.), ("-1267650600228229401496703205376", "1"));
667-
test(684729.48391f64, ("367611342500051", "536870912"));
668-
test(-8573.5918555, ("-4713381968463931", "549755813888"));
669-
test(1.0 / 2f64.pow(&100.), ("1", "1267650600228229401496703205376"));
670-
}
671-
672-
#[test]
673-
fn test_from_float_fail() {
674-
use std::{f32, f64};
675-
676-
assert_eq!(Ratio::from_float(f32::NAN), None);
677-
assert_eq!(Ratio::from_float(f32::INFINITY), None);
678-
assert_eq!(Ratio::from_float(f32::NEG_INFINITY), None);
679-
assert_eq!(Ratio::from_float(f64::NAN), None);
680-
assert_eq!(Ratio::from_float(f64::INFINITY), None);
681-
assert_eq!(Ratio::from_float(f64::NEG_INFINITY), None);
682-
}
683624
}

0 commit comments

Comments
 (0)