]> git.lizzy.rs Git - rust.git/log
rust.git
10 years agoauto merge of #11987 : cmr/rust/rm-rustpkg, r=cmr
bors [Sun, 2 Feb 2014 09:11:27 +0000 (01:11 -0800)]
auto merge of #11987 : cmr/rust/rm-rustpkg, r=cmr

I'm sorry :'(

Closes #11859

10 years agoRemove rustpkg.
Corey Richardson [Sun, 2 Feb 2014 07:56:55 +0000 (02:56 -0500)]
Remove rustpkg.

I'm sorry :'(

Closes #11859

10 years agoauto merge of #11948 : huonw/rust/show, r=alexcrichton
bors [Sun, 2 Feb 2014 06:31:26 +0000 (22:31 -0800)]
auto merge of #11948 : huonw/rust/show, r=alexcrichton

- renames `Default` to `Show`
- introduces some hidden `std::fmt::secret_...` functions, designed to work-around the lack of UFCS (with UFCS they can be replaced by referencing the trait methods directly) because I'm going to convert the traits to have methods rather than static functions, since `#[deriving]` works much better with true methods.

I'm blocked on a snapshot after this. (I could probably do a large number of `#[cfg]`s, but I can work on other things in the meantime.)

10 years agoRemove the SNAP line to work around #11985.
Huon Wilson [Sun, 2 Feb 2014 05:22:54 +0000 (16:22 +1100)]
Remove the SNAP line to work around #11985.

10 years agostd::fmt: prepare to convert the formatting traits to methods, and work
Huon Wilson [Fri, 31 Jan 2014 10:32:39 +0000 (21:32 +1100)]
std::fmt: prepare to convert the formatting traits to methods, and work
around the lack of UFCS.

The further work is pending a snapshot, to avoid putting #[cfg(stage0)]
attributes on all the traits and duplicating them.

10 years agoauto merge of #11975 : jfager/rust/r8498, r=alexcrichton
bors [Sun, 2 Feb 2014 03:16:26 +0000 (19:16 -0800)]
auto merge of #11975 : jfager/rust/r8498, r=alexcrichton

Closes #8498

10 years agostd: rename fmt::Default to `Show`.
Huon Wilson [Wed, 29 Jan 2014 13:46:37 +0000 (00:46 +1100)]
std: rename fmt::Default to `Show`.

This is a better name with which to have a #[deriving] mode.

Decision in:
https://github.com/mozilla/rust/wiki/Meeting-weekly-2014-01-28

10 years agoauto merge of #11959 : omasanori/rust/update-zsh, r=brson
bors [Sun, 2 Feb 2014 01:26:24 +0000 (17:26 -0800)]
auto merge of #11959 : omasanori/rust/update-zsh, r=brson

Updating the list of options and sorting it.

10 years agoauto merge of #11840 : cmr/rust/cstr, r=kballard
bors [Sat, 1 Feb 2014 23:46:25 +0000 (15:46 -0800)]
auto merge of #11840 : cmr/rust/cstr, r=kballard

10 years agoimpl Eq for CString
Corey Richardson [Fri, 31 Jan 2014 00:10:07 +0000 (19:10 -0500)]
impl Eq for CString

10 years agoimpl Clone for CString
Corey Richardson [Mon, 27 Jan 2014 11:12:59 +0000 (06:12 -0500)]
impl Clone for CString

Clone tests

10 years agoauto merge of #11974 : huonw/rust/no-at-vec, r=pcwalton
bors [Sat, 1 Feb 2014 19:16:24 +0000 (11:16 -0800)]
auto merge of #11974 : huonw/rust/no-at-vec, r=pcwalton

This removes @[] from the parser as well as much of the handling of it (and `@str`) from the compiler as I can find.

I've just rebased @pcwalton's (already reviewed) `@str` removal (and fixed the problems in a separate commit); the only new work is the trailing commits with my authorship.

Closes #11967

10 years agoauto merge of #11973 : dotdash/rust/u64_to_bytes, r=huonw
bors [Sat, 1 Feb 2014 18:01:25 +0000 (10:01 -0800)]
auto merge of #11973 : dotdash/rust/u64_to_bytes, r=huonw

LLVM fails to properly optimize the shifts used to convert the source
value to the right endianess. The resulting assembly copies the value
to the stack one byte at a time even when there's no conversion required
(e.g. u64_to_le_bytes on a little endian machine).

Instead of doing the conversion ourselves using shifts, we can use the
existing intrinsics to perform the endianess conversion and then
transmute the value to get a fixed vector of its bytes.

Before:
````
test be_i8  ... bench:     21442 ns/iter (+/- 70)
test be_i16 ... bench:     21447 ns/iter (+/- 45)
test be_i32 ... bench:     23832 ns/iter (+/- 63)
test be_i64 ... bench:     26887 ns/iter (+/- 267)

test le_i8  ... bench:     21442 ns/iter (+/- 56)
test le_i16 ... bench:     21448 ns/iter (+/- 36)
test le_i32 ... bench:     23825 ns/iter (+/- 153)
test le_i64 ... bench:     26271 ns/iter (+/- 138)
````
After:
````
test be_i8  ... bench:     21438 ns/iter (+/- 10)
test be_i16 ... bench:     21441 ns/iter (+/- 15)
test be_i32 ... bench:     19057 ns/iter (+/- 6)
test be_i64 ... bench:     21439 ns/iter (+/- 34)

test le_i8  ... bench:     21438 ns/iter (+/- 19)
test le_i16 ... bench:     21439 ns/iter (+/- 8)
test le_i32 ... bench:     21439 ns/iter (+/- 19)
test le_i64 ... bench:     21438 ns/iter (+/- 22)
````

10 years agoun-xfail test for #8498 and replace prints w/ asserts
Jason Fager [Sat, 1 Feb 2014 17:36:59 +0000 (12:36 -0500)]
un-xfail test for #8498 and replace prints w/ asserts

10 years agorustc: update docs & propagate @[]/@str removal more.
Huon Wilson [Sat, 1 Feb 2014 15:53:54 +0000 (02:53 +1100)]
rustc: update docs & propagate @[]/@str removal more.

Various functions can now be made specific to ~[], or just non-managed
vectors.

10 years agosyntax: remove the unused Vstore enum.
Huon Wilson [Sat, 1 Feb 2014 13:12:34 +0000 (00:12 +1100)]
syntax: remove the unused Vstore enum.

Seems to have been replaced by ExprVstore.

10 years agorustc: Remove the vstore handling of @str and @[].
Huon Wilson [Sat, 1 Feb 2014 13:09:11 +0000 (00:09 +1100)]
rustc: Remove the vstore handling of @str and @[].

10 years agosyntax: remove the handling of @str and @[] from the parser completely.
Huon Wilson [Sat, 1 Feb 2014 13:08:39 +0000 (00:08 +1100)]
syntax: remove the handling of @str and @[] from the parser completely.

10 years agosyntax: add an obsolete syntax warning for @[].
Huon Wilson [Sat, 1 Feb 2014 12:18:45 +0000 (23:18 +1100)]
syntax: add an obsolete syntax warning for @[].

10 years agorustc: remove use of @[].
Huon Wilson [Sat, 1 Feb 2014 04:57:59 +0000 (15:57 +1100)]
rustc: remove use of @[].

10 years agosyntax: convert LitBinary from @[u8] to Rc<~[u8]>.
Huon Wilson [Sat, 1 Feb 2014 04:54:41 +0000 (15:54 +1100)]
syntax: convert LitBinary from @[u8] to Rc<~[u8]>.

10 years agoUpdate/delete tests using @[].
Huon Wilson [Sat, 1 Feb 2014 04:52:41 +0000 (15:52 +1100)]
Update/delete tests using @[].

10 years agoarena: stop using @[].
Huon Wilson [Sat, 1 Feb 2014 04:53:11 +0000 (15:53 +1100)]
arena: stop using @[].

10 years agostd,extra: remove use of & support for @[].
Huon Wilson [Sat, 1 Feb 2014 04:57:17 +0000 (15:57 +1100)]
std,extra: remove use of & support for @[].

10 years agoChanges from the review of the @str PR.
Huon Wilson [Sat, 1 Feb 2014 15:53:26 +0000 (02:53 +1100)]
Changes from the review of the @str PR.

10 years agoFix `@str` removal tests.
Huon Wilson [Sat, 1 Feb 2014 15:19:55 +0000 (02:19 +1100)]
Fix `@str` removal tests.

10 years agoauto merge of #11944 : nathanielherman/rust/vec_opt, r=alexcrichton
bors [Sat, 1 Feb 2014 15:21:23 +0000 (07:21 -0800)]
auto merge of #11944 : nathanielherman/rust/vec_opt, r=alexcrichton

Closes #11733

10 years agolibrustc: Remove `@str` from the language
Patrick Walton [Sat, 1 Feb 2014 02:25:08 +0000 (18:25 -0800)]
librustc: Remove `@str` from the language

10 years agolibextra: Remove `@str` from all the libraries
Patrick Walton [Sat, 1 Feb 2014 00:50:45 +0000 (16:50 -0800)]
libextra: Remove `@str` from all the libraries

10 years agodoc: Remove references to `@str` from the documentation
Patrick Walton [Sat, 1 Feb 2014 00:45:12 +0000 (16:45 -0800)]
doc: Remove references to `@str` from the documentation

10 years agolibsyntax: Remove `@str` from the interner
Patrick Walton [Sat, 1 Feb 2014 00:42:33 +0000 (16:42 -0800)]
libsyntax: Remove `@str` from the interner

10 years agotest: Remove `@str` from the test suite
Patrick Walton [Sat, 1 Feb 2014 00:20:57 +0000 (16:20 -0800)]
test: Remove `@str` from the test suite

10 years agolibrustc: Remove one more `@str` from librustc
Patrick Walton [Sat, 1 Feb 2014 00:17:48 +0000 (16:17 -0800)]
librustc: Remove one more `@str` from librustc

10 years agolibsyntax: Remove an `@str` in pretty printing
Patrick Walton [Sat, 1 Feb 2014 00:14:42 +0000 (16:14 -0800)]
libsyntax: Remove an `@str` in pretty printing

10 years agolibsyntax: Remove the `interner_get` function and all uses
Patrick Walton [Sat, 1 Feb 2014 00:10:06 +0000 (16:10 -0800)]
libsyntax: Remove the `interner_get` function and all uses

10 years agolibrustc: Remove uses of `interner_get` in librustc
Patrick Walton [Sat, 1 Feb 2014 00:03:55 +0000 (16:03 -0800)]
librustc: Remove uses of `interner_get` in librustc

10 years agolibsyntax: Remove uses of `token::ident_to_str()`
Patrick Walton [Fri, 31 Jan 2014 23:30:19 +0000 (15:30 -0800)]
libsyntax: Remove uses of `token::ident_to_str()`

10 years agolibsyntax: Remove many uses of `token::ident_to_str`
Patrick Walton [Fri, 31 Jan 2014 23:26:59 +0000 (15:26 -0800)]
libsyntax: Remove many uses of `token::ident_to_str`

10 years agolibrustc: Remove uses of `token::ident_to_str()` from librustc
Patrick Walton [Fri, 31 Jan 2014 23:17:42 +0000 (15:17 -0800)]
librustc: Remove uses of `token::ident_to_str()` from librustc

10 years agolibrustc: Get rid of `ident_to_str` calls in resolve
Patrick Walton [Fri, 31 Jan 2014 21:48:49 +0000 (13:48 -0800)]
librustc: Get rid of `ident_to_str` calls in resolve

10 years agolibrustc: Get rid of calls to `token::ident_to_str` in debug info
Patrick Walton [Fri, 31 Jan 2014 21:15:53 +0000 (13:15 -0800)]
librustc: Get rid of calls to `token::ident_to_str` in debug info

10 years agolibrustc: De-`@str` `ident()` and `str_of()`
Patrick Walton [Fri, 31 Jan 2014 20:46:23 +0000 (12:46 -0800)]
librustc: De-`@str` `ident()` and `str_of()`

10 years agolibrustc: De-`@str` the LLVM symbol list
Patrick Walton [Fri, 31 Jan 2014 20:42:39 +0000 (12:42 -0800)]
librustc: De-`@str` the LLVM symbol list

10 years agolibrustc: De-`@str` type short names
Patrick Walton [Fri, 31 Jan 2014 20:36:00 +0000 (12:36 -0800)]
librustc: De-`@str` type short names

10 years agolibrustc: De-`@str` liveness
Patrick Walton [Fri, 31 Jan 2014 20:33:42 +0000 (12:33 -0800)]
librustc: De-`@str` liveness

10 years agolibrustc: De-`@str` symbol hashing
Patrick Walton [Fri, 31 Jan 2014 20:31:46 +0000 (12:31 -0800)]
librustc: De-`@str` symbol hashing

10 years agolibrustc: De-`@str` debuginfo
Patrick Walton [Fri, 31 Jan 2014 20:28:56 +0000 (12:28 -0800)]
librustc: De-`@str` debuginfo

10 years agolibrustc: De-`@str` resolve
Patrick Walton [Fri, 31 Jan 2014 20:25:11 +0000 (12:25 -0800)]
librustc: De-`@str` resolve

10 years agolibrustc: Remove a bunch of `@str` from the compiler around metadata
Patrick Walton [Fri, 31 Jan 2014 20:17:03 +0000 (12:17 -0800)]
librustc: Remove a bunch of `@str` from the compiler around metadata
handling

10 years agolibsyntax: Fix tests.
Patrick Walton [Fri, 31 Jan 2014 02:46:19 +0000 (18:46 -0800)]
libsyntax: Fix tests.

10 years agolibsyntax: De-`@str` `MacroDef`
Patrick Walton [Fri, 31 Jan 2014 00:07:26 +0000 (16:07 -0800)]
libsyntax: De-`@str` `MacroDef`

10 years agolibrustc: De-`@str` `NameAndSpan`
Patrick Walton [Thu, 30 Jan 2014 23:53:09 +0000 (15:53 -0800)]
librustc: De-`@str` `NameAndSpan`

10 years agolibrustc: Fix merge fallout.
Patrick Walton [Tue, 21 Jan 2014 18:08:10 +0000 (10:08 -0800)]
librustc: Fix merge fallout.

10 years agolibsyntax: Remove `ident_to_str` from the parser, which was returning
Patrick Walton [Thu, 16 Jan 2014 02:38:34 +0000 (18:38 -0800)]
libsyntax: Remove `ident_to_str` from the parser, which was returning
`@str` values

10 years agolibsyntax: De-`@str` `get_single_str_from_tts`
Patrick Walton [Thu, 16 Jan 2014 02:33:33 +0000 (18:33 -0800)]
libsyntax: De-`@str` `get_single_str_from_tts`

10 years agolibsyntax: Remove all `@str` from the AST
Patrick Walton [Thu, 16 Jan 2014 02:30:40 +0000 (18:30 -0800)]
libsyntax: Remove all `@str` from the AST

10 years agolibsyntax: Make float literals not use `@str`
Patrick Walton [Thu, 16 Jan 2014 01:15:39 +0000 (17:15 -0800)]
libsyntax: Make float literals not use `@str`

10 years agolibsyntax: De-`@str` pathnames
Patrick Walton [Thu, 16 Jan 2014 00:42:51 +0000 (16:42 -0800)]
libsyntax: De-`@str` pathnames

10 years agolibrustc: Stop using `@str` for source.
Patrick Walton [Thu, 16 Jan 2014 00:26:20 +0000 (16:26 -0800)]
librustc: Stop using `@str` for source.

10 years agolibsyntax: Remove the unnecessary `src` field from the lexer
Patrick Walton [Thu, 16 Jan 2014 00:01:14 +0000 (16:01 -0800)]
libsyntax: Remove the unnecessary `src` field from the lexer

10 years agolibrustc: Fix merge fallout.
Patrick Walton [Mon, 13 Jan 2014 23:06:50 +0000 (15:06 -0800)]
librustc: Fix merge fallout.

10 years agolibsyntax: De-`@str` `to_source`
Patrick Walton [Sat, 11 Jan 2014 01:20:07 +0000 (17:20 -0800)]
libsyntax: De-`@str` `to_source`

10 years agolibsyntax: De-`@str` literal strings in the AST
Patrick Walton [Fri, 10 Jan 2014 22:02:36 +0000 (14:02 -0800)]
libsyntax: De-`@str` literal strings in the AST

10 years agolibsyntax: Introduce an `InternedString` type to reduce `@str` in the
Patrick Walton [Wed, 8 Jan 2014 18:35:15 +0000 (10:35 -0800)]
libsyntax: Introduce an `InternedString` type to reduce `@str` in the
compiler and use it for attributes

10 years agoOptimize u64_to_{le,be}_bytes
Björn Steinbrink [Sat, 1 Feb 2014 13:56:51 +0000 (14:56 +0100)]
Optimize u64_to_{le,be}_bytes

LLVM fails to properly optimize the shifts used to convert the source
value to the right endianess. The resulting assembly copies the value
to the stack one byte at a time even when there's no conversion required
(e.g. u64_to_le_bytes on a little endian machine).

Instead of doing the conversion ourselves using shifts, we can use the
existing intrinsics to perform the endianess conversion and then
transmute the value to get a fixed vector of its bytes.

Before:

test be_i8  ... bench:     21442 ns/iter (+/- 70)
test be_i16 ... bench:     21447 ns/iter (+/- 45)
test be_i32 ... bench:     23832 ns/iter (+/- 63)
test be_i64 ... bench:     26887 ns/iter (+/- 267)

test le_i8  ... bench:     21442 ns/iter (+/- 56)
test le_i16 ... bench:     21448 ns/iter (+/- 36)
test le_i32 ... bench:     23825 ns/iter (+/- 153)
test le_i64 ... bench:     26271 ns/iter (+/- 138)

After:

test be_i8  ... bench:     21438 ns/iter (+/- 10)
test be_i16 ... bench:     21441 ns/iter (+/- 15)
test be_i32 ... bench:     19057 ns/iter (+/- 6)
test be_i64 ... bench:     21439 ns/iter (+/- 34)

test le_i8  ... bench:     21438 ns/iter (+/- 19)
test le_i16 ... bench:     21439 ns/iter (+/- 8)
test le_i32 ... bench:     21439 ns/iter (+/- 19)
test le_i64 ... bench:     21438 ns/iter (+/- 22)

10 years agoauto merge of #11932 : dmanescu/rust/11741-stability-cross-crate, r=alexcrichton
bors [Sat, 1 Feb 2014 13:31:24 +0000 (05:31 -0800)]
auto merge of #11932 : dmanescu/rust/11741-stability-cross-crate, r=alexcrichton

Fixes #11741
Added tests and removed xfail-fast from run-pass/simd-experimental which is now fixed (see #11738).

10 years agoauto merge of #11930 : bjz/rust/next_power_of_two, r=huonw
bors [Sat, 1 Feb 2014 12:11:21 +0000 (04:11 -0800)]
auto merge of #11930 : bjz/rust/next_power_of_two, r=huonw

10 years agoauto merge of #11963 : alexcrichton/rust/fix-rustpkg, r=brson
bors [Sat, 1 Feb 2014 08:46:23 +0000 (00:46 -0800)]
auto merge of #11963 : alexcrichton/rust/fix-rustpkg, r=brson

Right now the bots are all injecting a libstd version, so all the rustpkg tests
are passing. All rustpkg compilations will fail unless the version number is
explicitly given because rustpkg attempts to exactly guess the target file name.
Switch back to using a pattern match in order to unbreak tests.

Closes #11852

10 years agoauto merge of #11789 : pongad/rust/master, r=kballard
bors [Sat, 1 Feb 2014 07:31:28 +0000 (23:31 -0800)]
auto merge of #11789 : pongad/rust/master, r=kballard

All tests passing. #5268

10 years agoauto merge of #11965 : alexcrichton/rust/issue-7385, r=alexcrichton
bors [Sat, 1 Feb 2014 06:21:38 +0000 (22:21 -0800)]
auto merge of #11965 : alexcrichton/rust/issue-7385, r=alexcrichton

I've verified that it works on osx x86_64

Closes #7385

Rolled up PRs:

Closes #11898
Closes #11934
Closes #11942
Closes #11952
Closes #11960
Closes #11966
Closes #11953

Closed issues:

Closes #4063
Closes #7911

10 years agoFixing tests
Alex Crichton [Sat, 1 Feb 2014 06:11:18 +0000 (22:11 -0800)]
Fixing tests

10 years agoRemove the need to count lang items
Alex Crichton [Wed, 8 Jan 2014 04:39:15 +0000 (20:39 -0800)]
Remove the need to count lang items

This solves horrible diffs where all you do is renumber literally everything.

10 years agoTest for null buffer in CString.len()/.iter() and fail
Kevin Ballard [Thu, 30 Jan 2014 23:29:36 +0000 (15:29 -0800)]
Test for null buffer in CString.len()/.iter() and fail

Also change .as_str() to fail on null buffer.

10 years agoRemove the obsolete handler for `impl A;`.
Huon Wilson [Fri, 31 Jan 2014 14:46:30 +0000 (01:46 +1100)]
Remove the obsolete handler for `impl A;`.

This is has been obsolete for quite a while now (including a release),
so removing the special handling seems fine. (The error message is quite
good still anyway.)

Fixes #9580.

10 years agoAdd test for sensible #[start] error message.
Huon Wilson [Fri, 31 Jan 2014 13:42:02 +0000 (00:42 +1100)]
Add test for sensible #[start] error message.

Fixes #9575.

10 years agoAdd test cases for #4063.
OGINO Masanori [Wed, 29 Jan 2014 16:04:14 +0000 (01:04 +0900)]
Add test cases for #4063.

Signed-off-by: OGINO Masanori <masanori.ogino@gmail.com>
10 years agomark the minimum supported Linux kernel version
Daniel Micay [Fri, 31 Jan 2014 14:58:00 +0000 (09:58 -0500)]
mark the minimum supported Linux kernel version

This is just taken from the binary itself. It would be nice to mark the
minimum glibc version too, and the corresponding RHEL/CentOS version.

10 years agomark Windows 8 as supported
Daniel Micay [Fri, 31 Jan 2014 14:53:17 +0000 (09:53 -0500)]
mark Windows 8 as supported

10 years agobump minimum supported OS X version to 10.7
Daniel Micay [Fri, 31 Jan 2014 14:50:44 +0000 (09:50 -0500)]
bump minimum supported OS X version to 10.7

Closes #11927
Closes #10842
Closes #2024

10 years agoAdd test case for issue 7911
JeremyLetang [Wed, 29 Jan 2014 00:54:19 +0000 (19:54 -0500)]
Add test case for issue 7911

10 years agoFix minor doc typos
Virgile Andreani [Thu, 30 Jan 2014 18:29:35 +0000 (19:29 +0100)]
Fix minor doc typos

10 years agoUn-xfail test for 7385
Alex Crichton [Sat, 1 Feb 2014 00:54:45 +0000 (16:54 -0800)]
Un-xfail test for 7385

I've verified that it works on osx x86_64

Closes #7385

10 years agoAdded minmax function.
Michael Darakananda [Sat, 25 Jan 2014 06:40:54 +0000 (22:40 -0800)]
Added minmax function.
Tests ok

10 years agoauto merge of #11768 : nikomatsakis/rust/issue-11385-cell-and-variance, r=pnkfelix
bors [Sat, 1 Feb 2014 03:36:41 +0000 (19:36 -0800)]
auto merge of #11768 : nikomatsakis/rust/issue-11385-cell-and-variance, r=pnkfelix

Introduce marker types for indicating variance and for opting out
of builtin bounds.

Fixes #10834.
Fixes #11385.
cc #5922.

r? @pnkfelix (since you reviewed the variance inference in the first place)

10 years agoauto merge of #11885 : bnoordhuis/rust/issue11694, r=alexcrichton
bors [Sat, 1 Feb 2014 02:21:41 +0000 (18:21 -0800)]
auto merge of #11885 : bnoordhuis/rust/issue11694, r=alexcrichton

EINVAL means that the requested stack size is either not a multiple
of the system page size or that it's smaller than PTHREAD_STACK_MIN.
Figure out what the case is, fix it up and retry.  If it still fails,
give up, like before.

Suggestions for future improvements:

  * don't fail!() but instead signal a condition, or
  * silently ignore the error and use a default sized stack.

Fixes #11694.

The first two commits put the framework in place, the third one contains the meat.

10 years agoIntroduce marker types for indicating variance and for opting out
Niko Matsakis [Wed, 22 Jan 2014 19:03:02 +0000 (14:03 -0500)]
Introduce marker types for indicating variance and for opting out
of builtin bounds.

Fixes #10834.
Fixes #11385.
cc #5922.

10 years agoMove int and uint overflow tests into macros
Brendan Zabarauskas [Thu, 30 Jan 2014 12:55:34 +0000 (23:55 +1100)]
Move int and uint overflow tests into macros

10 years agoRemove free-standing div functions in std::uint
Brendan Zabarauskas [Thu, 30 Jan 2014 11:39:58 +0000 (22:39 +1100)]
Remove free-standing div functions in std::uint

10 years agoRemove some unused imports
Brendan Zabarauskas [Thu, 30 Jan 2014 10:18:30 +0000 (21:18 +1100)]
Remove some unused imports

10 years agoMake next_power_of_two generic for unsigned integers
Brendan Zabarauskas [Thu, 30 Jan 2014 05:35:17 +0000 (16:35 +1100)]
Make next_power_of_two generic for unsigned integers

Also rename `next_power_of_two_opt` to `checked_next_power_of_two`.

10 years agoFix rustpkg tests with --disable-inject-std-version
Alex Crichton [Fri, 31 Jan 2014 23:56:37 +0000 (15:56 -0800)]
Fix rustpkg tests with --disable-inject-std-version

Right now the bots are all injecting a libstd version, so all the rustpkg tests
are passing. All rustpkg compilations will fail unless the version number is
explicitly given because rustpkg attempts to exactly guess the target file name.
Switch back to using a pattern match in order to unbreak tests.

Closes #11852

10 years agoauto merge of #11810 : Armavica/rust/issue-11645, r=alexcrichton
bors [Fri, 31 Jan 2014 23:11:32 +0000 (15:11 -0800)]
auto merge of #11810 : Armavica/rust/issue-11645, r=alexcrichton

The doc-generating tool comments out the lines that match `/$# /` (note the space), which is not what is wanted here. And it lets live the lines matching `/$#[^ ]/`. But we still want to see a space. So I replaced the normal space by a non breakable one, which fools the parser into displaying the line.

10 years agoUpdate the zsh completion file for rustc.
OGINO Masanori [Fri, 31 Jan 2014 23:00:02 +0000 (08:00 +0900)]
Update the zsh completion file for rustc.

Signed-off-by: OGINO Masanori <masanori.ogino@gmail.com>
10 years agoauto merge of #11832 : jfager/rust/r5900, r=alexcrichton
bors [Fri, 31 Jan 2014 21:06:39 +0000 (13:06 -0800)]
auto merge of #11832 : jfager/rust/r5900, r=alexcrichton

I tried a couple of different ways to squash this, and still don't think this is ideal, but I wanted to get it out for feedback.

Closes #5900
Closes #9942

There are a few scenarios where the compiler tries to evaluate CastExprs without the corresponding types being available yet in the type context:  https://github.com/mozilla/rust/issues/10618, https://github.com/mozilla/rust/issues/5900, https://github.com/mozilla/rust/issues/9942

This PR takes the approach of having eval_const_expr_partial's CastExpr arm fall back to a limited ast_ty_to_ty call that only checks for (a subset of) valid const types, when the direct type lookup fails.  It's kind of hacky, so I understand if you don't want to take this as is.  I'd need a little mentoring to get this into better shape, as figuring out the proper fix has been a little daunting. I'm also happy if someone else wants to pick this up and run with it.

This closes 5900 and 9942, but only moves the goalposts a little on 10618, which now falls over in a later phase of the compiler.

10 years agoauto merge of #11955 : alexcrichton/rust/fix-unwinding-on-mac-64, r=cmr
bors [Fri, 31 Jan 2014 19:21:33 +0000 (11:21 -0800)]
auto merge of #11955 : alexcrichton/rust/fix-unwinding-on-mac-64, r=cmr

I believe that this is leading to lots of failures on the bots.

cc #11954

10 years agoDisable fp elim on mac64
Alex Crichton [Fri, 31 Jan 2014 18:18:13 +0000 (10:18 -0800)]
Disable fp elim on mac64

I believe that this is leading to lots of failures on the bots.

cc #11954

10 years agoauto merge of #11917 : thestinger/rust/intrinsic, r=alexcrichton
bors [Fri, 31 Jan 2014 18:01:48 +0000 (10:01 -0800)]
auto merge of #11917 : thestinger/rust/intrinsic, r=alexcrichton

10 years agoauto merge of #11933 : kini/rust/patch-1, r=alexcrichton
bors [Fri, 31 Jan 2014 16:46:34 +0000 (08:46 -0800)]
auto merge of #11933 : kini/rust/patch-1, r=alexcrichton

Text refers to "the type shown earlier", when the type in
question was not in fact shown earlier.  I assume this is
an artifact of an earlier revision.

10 years agoauto merge of #11929 : FlaPer87/rust/issue-11681, r=huonw
bors [Fri, 31 Jan 2014 13:36:31 +0000 (05:36 -0800)]
auto merge of #11929 : FlaPer87/rust/issue-11681, r=huonw

closes #11681

10 years agoUse __pthread_get_minstack() when available.
Ben Noordhuis [Wed, 29 Jan 2014 17:19:23 +0000 (18:19 +0100)]
Use __pthread_get_minstack() when available.

glibc >= 2.15 has a __pthread_get_minstack() function that returns
PTHREAD_STACK_MIN plus however many bytes are needed for thread-local
storage.  Use it when it's available because just PTHREAD_STACK_MIN is
not enough in applications that have big thread-local storage
requirements.

Fixes #6233.