Skip to content

Commit 3a16747

Browse files
committed
---
yaml --- r: 66510 b: refs/heads/master c: d5c5ce3 h: refs/heads/master v: v3
1 parent 0917f50 commit 3a16747

File tree

27 files changed

+105
-101
lines changed

27 files changed

+105
-101
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
refs/heads/master: fd192891085ecb3c4fee458b2dc374aa5d1ed18d
2+
refs/heads/master: d5c5ce3f8d07ba7f9059727a790ce19f7a1599b7
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 18e3db7392d2d0697b7e27d6d986139960144d85
55
refs/heads/try: 7b78b52e602bb3ea8174f9b2006bff3315f03ef9

trunk/Makefile.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ endif
139139

140140
# version-string calculation
141141
CFG_GIT_DIR := $(CFG_SRC_DIR).git
142-
CFG_RELEASE = 0.7-pre
142+
CFG_RELEASE = 0.7
143143
CFG_VERSION = $(CFG_RELEASE)
144144
# windows exe's need numeric versions - don't use anything but
145145
# numbers and dots here

trunk/README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -42,9 +42,9 @@ packages:
4242
Assuming you're on a relatively modern *nix system and have met the
4343
prerequisites, something along these lines should work.
4444

45-
$ curl -O http://static.rust-lang.org/dist/rust-0.6.tar.gz
46-
$ tar -xzf rust-0.6.tar.gz
47-
$ cd rust-0.6
45+
$ curl -O http://static.rust-lang.org/dist/rust-0.7.tar.gz
46+
$ tar -xzf rust-0.7.tar.gz
47+
$ cd rust-0.7
4848
$ ./configure
4949
$ make && make install
5050

@@ -59,8 +59,8 @@ When complete, `make install` will place several programs into
5959
API-documentation tool, and `rustpkg`, the Rust package manager and build system.
6060

6161
[wiki-start]: https://github.com/mozilla/rust/wiki/Note-getting-started-developing-Rust
62-
[tarball]: http://static.rust-lang.org/dist/rust-0.6.tar.gz
63-
[win-exe]: http://static.rust-lang.org/dist/rust-0.6-install.exe
62+
[tarball]: http://static.rust-lang.org/dist/rust-0.7.tar.gz
63+
[win-exe]: http://static.rust-lang.org/dist/rust-0.7-install.exe
6464

6565

6666
## License

trunk/RELEASES.txt

Lines changed: 35 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,54 +1,56 @@
11
Version 0.7 (July 2013)
22
-----------------------
33

4-
* ??? changes, numerous bugfixes
4+
* ~2000 changes, numerous bugfixes
55

6-
* Syntax changes
6+
* Language
77
* `impl`s no longer accept a visibility qualifier. Put them on methods
88
instead.
9-
* `use mod` is no longer valid.
10-
* `fail!` and `assert!` accept `~str`, `&'static str` or `fmt!`-style
11-
argument list.
12-
* `Encodable`, `Decodable`, `Ord`, `TotalOrd`, `TotalEq`, `DeepClone`,
13-
`Rand`, `Zero` and `ToStr` can all be automatically derived with
14-
`#[deriving(...)]`.
15-
* The `Durable` trait is replaced with the `'static` bounds.
16-
* At long last, 'argument modes' no longer exist.
17-
* The `bytes!` macro returns a vector of bytes for string, u8, char,
18-
and unsuffixed integer literals.
19-
* `#[static_assert]` makes compile-time assertions about static bools.
20-
21-
* Semantic changes
229
* The borrow checker has been rewritten with flow-sensitivity, fixing
2310
many bugs and inconveniences.
2411
* The `self` parameter no longer implicitly means `&'self self`,
2512
and can be explicitly marked with a lifetime.
26-
* Structs with the `#[packed]` attribute have byte alignment and
27-
no padding between fields.
13+
* Overloadable compound operators (`+=`, etc.) have been temporarily
14+
removed due to bugs.
2815
* The `for` loop protocol now requires `for`-iterators to return `bool`
2916
so they compose better.
17+
* The `Durable` trait is replaced with the `'static` bounds.
3018
* Trait default methods work more often.
19+
* Structs with the `#[packed]` attribute have byte alignment and
20+
no padding between fields.
3121
* Type parameters bound by `Copy` must now be copied explicitly with
3222
the `copy` keyword.
3323
* It is now illegal to move out of a dereferenced unsafe pointer.
3424
* `Option<~T>` is now represented as a nullable pointer.
3525
* `@mut` does dynamic borrow checks correctly.
36-
* Macros TODO
3726
* The `main` function is only detected at the topmost level of the crate.
3827
The `#[main]` attribute is still valid anywhere.
3928
* Struct fields may no longer be mutable. Use inherited mutability.
40-
* The `#[non_owned]` attribute makes a type that would otherwise be
41-
`Owned`, not. TODO this may change to non_send before 0.7
42-
* The `#[mutable]` attribute makes a type that would otherwise be
43-
`Const`, note. TODO this may change to non_freeze before 0.7
29+
* The `#[no_send]` attribute makes a type that would otherwise be
30+
`Send`, not.
31+
* The `#[no_freeze]` attribute makes a type that would otherwise be
32+
`Freeze`, not.
4433
* Unbounded recursion will abort the process after reaching the limit
4534
specified by the `RUST_MAX_STACK` environment variable (default: 1GB).
4635
* The `vecs_implicitly_copyable` lint mode has been removed. Vectors
4736
are never implicitly copyable.
37+
* `#[static_assert]` makes compile-time assertions about static bools.
38+
* At long last, 'argument modes' no longer exist.
39+
* The rarely used `use mod` statement no longer exists.
40+
41+
* Syntax extensions
42+
* `fail!` and `assert!` accept `~str`, `&'static str` or `fmt!`-style
43+
argument list.
44+
* `Encodable`, `Decodable`, `Ord`, `TotalOrd`, `TotalEq`, `DeepClone`,
45+
`Rand`, `Zero` and `ToStr` can all be automatically derived with
46+
`#[deriving(...)]`.
47+
* The `bytes!` macro returns a vector of bytes for string, u8, char,
48+
and unsuffixed integer literals.
4849

4950
* Libraries
5051
* The `core` crate was renamed to `std`.
5152
* The `std` crate was renamed to `extra`.
53+
* More and improved documentation.
5254
* std: `iterator` module for external iterator objects.
5355
* Many old-style (internal, higher-order function) iterators replaced by
5456
implementations of `Iterator`.
@@ -91,8 +93,16 @@ Version 0.7 (July 2013)
9193
* extra: Implementation of fixed output size variations of SHA-2.
9294

9395
* Tooling
94-
* `unused_unsafe` lint mode for detecting unnecessary `unsafe` blocks.
95-
* `unused_mut` lint mode for identifying unused `mut` qualifiers.
96+
* `unused_variable` lint mode for unused variables (default: warn).
97+
* `unused_unsafe` lint mode for detecting unnecessary `unsafe` blocks
98+
(default: warn).
99+
* `unused_mut` lint mode for identifying unused `mut` qualifiers
100+
(default: warn).
101+
* `dead_assignment` lint mode for unread variables (default: warn).
102+
* `unnecessary_allocation` lint mode detects some heap allocations that are
103+
immediately borrowed so could be written without allocating (default: warn).
104+
* `missing_doc` lint mode (default: allow).
105+
* `unreachable_code` lint mode (default: warn).
96106
* The `rusti` command has been rewritten and a number of bugs addressed.
97107
* rustc outputs in color on more terminals.
98108
* rustc accepts a `--link-args` flag to pass arguments to the linker.
@@ -101,12 +111,7 @@ Version 0.7 (July 2013)
101111
dynamic borrowcheck failures for debugging.
102112
* rustdoc has a nicer stylesheet.
103113
* Various improvements to rustdoc.
104-
* Improvements to rustpkg (see the detailed release notes)
105-
106-
* Other
107-
* More and improved library documentation.
108-
* Various improvements on ARM and Android.
109-
* Various improvements to MIPS backend.
114+
* Improvements to rustpkg (see the detailed release notes).
110115

111116
Version 0.6 (April 2013)
112117
------------------------

trunk/src/compiletest/compiletest.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515
#[no_core]; // XXX: Remove after snapshot
1616
#[no_std];
1717

18-
extern mod core(name = "std", vers = "0.7-pre");
19-
extern mod extra(name = "extra", vers = "0.7-pre");
18+
extern mod core(name = "std", vers = "0.7");
19+
extern mod extra(name = "extra", vers = "0.7");
2020

2121
use core::prelude::*;
2222
use core::*;

trunk/src/driver/driver.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
#[no_core];
1212
#[no_std];
1313

14-
extern mod core(name = "std", vers = "0.7-pre");
14+
extern mod core(name = "std", vers = "0.7");
1515

1616
#[cfg(rustpkg)]
1717
extern mod this(name = "rustpkg");

trunk/src/etc/kate/rust.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<!ENTITY rustIdent "[a-zA-Z_][a-zA-Z_0-9]*">
88
<!ENTITY rustIntSuf "([iu](8|16|32|64)?)?">
99
]>
10-
<language name="Rust" version="0.7-pre" kateversion="2.4" section="Sources" extensions="*.rs;*.rc" mimetype="text/x-rust" priority="15">
10+
<language name="Rust" version="0.7" kateversion="2.4" section="Sources" extensions="*.rs;*.rc" mimetype="text/x-rust" priority="15">
1111
<highlighting>
1212
<list name="fn">
1313
<item> fn </item>

trunk/src/libextra/extra.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ Rust extras are part of the standard Rust distribution.
2121
*/
2222

2323
#[link(name = "extra",
24-
vers = "0.7-pre",
24+
vers = "0.7",
2525
uuid = "122bed0b-c19b-4b82-b0b7-7ae8aead7297",
2626
url = "https://github.com/mozilla/rust/tree/master/src/libextra")];
2727

trunk/src/librust/rust.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
// FIXME #2238 Make run only accept source that emits an executable
1414

1515
#[link(name = "rust",
16-
vers = "0.7-pre",
16+
vers = "0.7",
1717
uuid = "4a24da33-5cc8-4037-9352-2cbe9bd9d27c",
1818
url = "https://github.com/mozilla/rust/tree/master/src/rust")];
1919

trunk/src/librustc/front/std_inject.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ use syntax::codemap::dummy_sp;
1818
use syntax::codemap;
1919
use syntax::fold;
2020

21-
static STD_VERSION: &'static str = "0.7-pre";
21+
static STD_VERSION: &'static str = "0.7";
2222

2323
pub fn maybe_inject_libstd_ref(sess: Session, crate: @ast::crate)
2424
-> @ast::crate {

trunk/src/librustc/front/test.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -271,7 +271,7 @@ mod __test {
271271
*/
272272

273273
fn mk_std(cx: &TestCtxt) -> @ast::view_item {
274-
let vers = ast::lit_str(@"0.7-pre");
274+
let vers = ast::lit_str(@"0.7");
275275
let vers = nospan(vers);
276276
let mi = ast::meta_name_value(@"vers", vers);
277277
let mi = nospan(mi);

trunk/src/librustc/middle/trans/base.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -996,13 +996,13 @@ pub fn do_spill_noroot(cx: block, v: ValueRef) -> ValueRef {
996996

997997
pub fn spill_if_immediate(cx: block, v: ValueRef, t: ty::t) -> ValueRef {
998998
let _icx = push_ctxt("spill_if_immediate");
999-
if ty::type_is_immediate(cx.tcx(), t) { return do_spill(cx, v, t); }
999+
if ty::type_is_immediate(t) { return do_spill(cx, v, t); }
10001000
return v;
10011001
}
10021002

10031003
pub fn load_if_immediate(cx: block, v: ValueRef, t: ty::t) -> ValueRef {
10041004
let _icx = push_ctxt("load_if_immediate");
1005-
if ty::type_is_immediate(cx.tcx(), t) { return Load(cx, v); }
1005+
if ty::type_is_immediate(t) { return Load(cx, v); }
10061006
return v;
10071007
}
10081008

@@ -1527,7 +1527,7 @@ pub fn mk_standard_basic_blocks(llfn: ValueRef) -> BasicBlocks {
15271527
// slot where the return value of the function must go.
15281528
pub fn make_return_pointer(fcx: fn_ctxt, output_type: ty::t) -> ValueRef {
15291529
unsafe {
1530-
if !ty::type_is_immediate(fcx.ccx.tcx, output_type) {
1530+
if !ty::type_is_immediate(output_type) {
15311531
llvm::LLVMGetParam(fcx.llfn, 0)
15321532
} else {
15331533
let lloutputtype = type_of::type_of(fcx.ccx, output_type);
@@ -1566,7 +1566,7 @@ pub fn new_fn_ctxt_w_id(ccx: @mut CrateContext,
15661566
ty::subst_tps(ccx.tcx, substs.tys, substs.self_ty, output_type)
15671567
}
15681568
};
1569-
let is_immediate = ty::type_is_immediate(ccx.tcx, substd_output_type);
1569+
let is_immediate = ty::type_is_immediate(substd_output_type);
15701570
let fcx = @mut fn_ctxt_ {
15711571
llfn: llfndecl,
15721572
llenv: unsafe {
@@ -1672,7 +1672,7 @@ pub fn copy_args_to_allocas(fcx: fn_ctxt,
16721672
match fcx.llself {
16731673
Some(slf) => {
16741674
let self_val = if slf.is_copy
1675-
&& datum::appropriate_mode(bcx.tcx(), slf.t).is_by_value() {
1675+
&& datum::appropriate_mode(slf.t).is_by_value() {
16761676
let tmp = BitCast(bcx, slf.v, type_of(bcx.ccx(), slf.t));
16771677
let alloc = alloc_ty(bcx, slf.t);
16781678
Store(bcx, tmp, alloc);
@@ -1700,7 +1700,7 @@ pub fn copy_args_to_allocas(fcx: fn_ctxt,
17001700
// This alloca should be optimized away by LLVM's mem-to-reg pass in
17011701
// the event it's not truly needed.
17021702
// only by value if immediate:
1703-
let llarg = if datum::appropriate_mode(bcx.tcx(), arg_ty).is_by_value() {
1703+
let llarg = if datum::appropriate_mode(arg_ty).is_by_value() {
17041704
let alloc = alloc_ty(bcx, arg_ty);
17051705
Store(bcx, raw_llarg, alloc);
17061706
alloc

trunk/src/librustc/middle/trans/callee.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -633,7 +633,7 @@ pub fn trans_call_inner(in_cx: block,
633633

634634
let mut llargs = ~[];
635635

636-
if !ty::type_is_immediate(bcx.tcx(), ret_ty) {
636+
if !ty::type_is_immediate(ret_ty) {
637637
llargs.push(llretslot);
638638
}
639639

@@ -680,7 +680,7 @@ pub fn trans_call_inner(in_cx: block,
680680
// case to ignore instead of invoking the Store
681681
// below into a scratch pointer of a mismatched
682682
// type.
683-
} else if ty::type_is_immediate(bcx.tcx(), ret_ty) {
683+
} else if ty::type_is_immediate(ret_ty) {
684684
let llscratchptr = alloc_ty(bcx, ret_ty);
685685
Store(bcx, llresult, llscratchptr);
686686
bcx = glue::drop_ty(bcx, llscratchptr, ret_ty);
@@ -694,7 +694,7 @@ pub fn trans_call_inner(in_cx: block,
694694
// If this is an immediate, store into the result location.
695695
// (If this was not an immediate, the result will already be
696696
// directly written into the output slot.)
697-
if ty::type_is_immediate(bcx.tcx(), ret_ty) {
697+
if ty::type_is_immediate(ret_ty) {
698698
Store(bcx, llresult, lldest);
699699
}
700700
}
@@ -898,7 +898,7 @@ pub fn trans_arg_expr(bcx: block,
898898
}
899899
ty::ByCopy => {
900900
if ty::type_needs_drop(bcx.tcx(), arg_datum.ty) ||
901-
arg_datum.appropriate_mode(bcx.tcx()).is_by_ref() {
901+
arg_datum.appropriate_mode().is_by_ref() {
902902
debug!("by copy arg with type %s, storing to scratch",
903903
bcx.ty_to_str(arg_datum.ty));
904904
let scratch = scratch_datum(bcx, arg_datum.ty, false);
@@ -914,7 +914,7 @@ pub fn trans_arg_expr(bcx: block,
914914
scratch.add_clean(bcx);
915915
temp_cleanups.push(scratch.val);
916916

917-
match scratch.appropriate_mode(bcx.tcx()) {
917+
match scratch.appropriate_mode() {
918918
ByValue => val = Load(bcx, scratch.val),
919919
ByRef(_) => val = scratch.val,
920920
}

trunk/src/librustc/middle/trans/datum.rs

Lines changed: 21 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ pub fn scratch_datum(bcx: block, ty: ty::t, zero: bool) -> Datum {
188188
Datum { val: scratch, ty: ty, mode: ByRef(RevokeClean) }
189189
}
190190

191-
pub fn appropriate_mode(tcx: ty::ctxt, ty: ty::t) -> DatumMode {
191+
pub fn appropriate_mode(ty: ty::t) -> DatumMode {
192192
/*!
193193
*
194194
* Indicates the "appropriate" mode for this value,
@@ -197,7 +197,7 @@ pub fn appropriate_mode(tcx: ty::ctxt, ty: ty::t) -> DatumMode {
197197

198198
if ty::type_is_nil(ty) || ty::type_is_bot(ty) {
199199
ByValue
200-
} else if ty::type_is_immediate(tcx, ty) {
200+
} else if ty::type_is_immediate(ty) {
201201
ByValue
202202
} else {
203203
ByRef(RevokeClean)
@@ -508,18 +508,18 @@ impl Datum {
508508
}
509509
}
510510

511-
pub fn appropriate_mode(&self, tcx: ty::ctxt) -> DatumMode {
511+
pub fn appropriate_mode(&self) -> DatumMode {
512512
/*! See the `appropriate_mode()` function */
513513

514-
appropriate_mode(tcx, self.ty)
514+
appropriate_mode(self.ty)
515515
}
516516

517517
pub fn to_appropriate_llval(&self, bcx: block) -> ValueRef {
518518
/*!
519519
*
520520
* Yields an llvalue with the `appropriate_mode()`. */
521521

522-
match self.appropriate_mode(bcx.tcx()) {
522+
match self.appropriate_mode() {
523523
ByValue => self.to_value_llval(bcx),
524524
ByRef(_) => self.to_ref_llval(bcx)
525525
}
@@ -530,7 +530,7 @@ impl Datum {
530530
*
531531
* Yields a datum with the `appropriate_mode()`. */
532532

533-
match self.appropriate_mode(bcx.tcx()) {
533+
match self.appropriate_mode() {
534534
ByValue => self.to_value_datum(bcx),
535535
ByRef(_) => self.to_ref_datum(bcx)
536536
}
@@ -657,7 +657,13 @@ impl Datum {
657657
ByValue => {
658658
// Actually, this case cannot happen right
659659
// now, because enums are never immediate.
660-
assert!(ty::type_is_immediate(bcx.tcx(), ty));
660+
// But in principle newtype'd immediate
661+
// values should be immediate, and in that
662+
// case the * would be a no-op except for
663+
// changing the type, so I am putting this
664+
// code in place here to do the right
665+
// thing if this change ever goes through.
666+
assert!(ty::type_is_immediate(ty));
661667
(Some(Datum {ty: ty, ..*self}), bcx)
662668
}
663669
};
@@ -689,7 +695,14 @@ impl Datum {
689695
)
690696
}
691697
ByValue => {
692-
assert!(ty::type_is_immediate(bcx.tcx(), ty));
698+
// Actually, this case cannot happen right now,
699+
// because structs are never immediate. But in
700+
// principle, newtype'd immediate values should be
701+
// immediate, and in that case the * would be a no-op
702+
// except for changing the type, so I am putting this
703+
// code in place here to do the right thing if this
704+
// change ever goes through.
705+
assert!(ty::type_is_immediate(ty));
693706
(Some(Datum {ty: ty, ..*self}), bcx)
694707
}
695708
}

0 commit comments

Comments
 (0)