Commit Graph

101 Commits

Author SHA1 Message Date
Patrick Walton
44ab00ee37 Revert "librustc: Make unqualified identifier searches terminate at the nearest module scope. r=tjc"
This reverts commit a8d37af247.
2013-01-08 19:29:16 -08:00
Patrick Walton
a8d37af247 librustc: Make unqualified identifier searches terminate at the nearest module scope. r=tjc 2013-01-08 19:27:57 -08:00
Tim Chevalier
89acd1f57f Rename option::get_default => get_or_default, get_zero => get_or_zero 2013-01-04 16:01:26 -08:00
Tim Chevalier
1f1e7e9616 Add option::get_zero
r=brson

Closes #3797
2013-01-04 00:46:55 -08:00
Patrick Walton
e26ca35b08 librustc: Fix the test runner, the condition system, and core test. rs=bustage 2012-12-27 17:53:04 -08:00
Patrick Walton
57c599914a librustc: Terminate name searches at the nearest module scope for paths that contain at least two components. r=graydon 2012-12-27 10:02:54 -08:00
Erick Tryzelaar
a0ef334179 core: use movable self to clean up option/result. 2012-12-18 20:54:13 -08:00
Brian Anderson
d809e89c26 Replace some Eq impls with deriving_eq 2012-12-13 16:14:28 -08:00
Patrick Walton
33c1e47c1b librustc: Implement moves based on type. r=nmatsakis 2012-12-04 15:38:04 -08:00
Graydon Hoare
00c856c0b1 Update license, add license boilerplate to most files. Remainder will follow. 2012-12-03 17:12:14 -08:00
Brian Anderson
8179e268ef Register snapshots 2012-11-28 12:33:00 -08:00
Patrick Walton
318e534895 rustc: Implement explicit self for Eq and Ord. r=graydon 2012-11-19 15:33:11 -08:00
Brian Anderson
c78020ef4f Whitespace 2012-11-08 17:11:44 -08:00
Brian J. Burg
a5718ba377 Change option::expect to not require a Copy bound, and move instead. 2012-11-08 16:25:22 -08:00
Tim Chevalier
11e92f37c1 Remove uses of binary move - <- - from tests and libraries 2012-10-23 12:10:03 -07:00
Tim Chevalier
10612ee30c Remove superfluous by-ref in option::get, option::get_default, option::expect
Superficial change, no review.
2012-10-19 11:38:28 -07:00
Erick Tryzelaar
fe41ccec64 Rename str::to_unique to str::to_owned. 2012-10-18 11:04:59 -07:00
Tim Chevalier
30a62793fa Make moves explicit in core tests 2012-10-12 20:43:37 -07:00
Tim Chevalier
1ab914df1d Write option::chain and result::chain with match move
Closes #3590
2012-10-11 14:17:59 -07:00
Tim Chevalier
65c96f849f Forbid deprecated modes again in core
Sadly, there's only one file that requires deprecated modes
(stackwalk)... So, forbid them everywhere else.
2012-10-04 16:48:57 -07:00
Tim Chevalier
fe12da0864 De-mode comm::Chan 2012-10-04 16:48:57 -07:00
Brian Anderson
c83218de12 core: Improve option docs a little 2012-10-04 15:15:09 -07:00
Tim Chevalier
f78cdcb636 Removing explicit uses of + mode
This removes most explicit uses of the + argument mode. Pending a
snapshot, I had to remove the forbid(deprecated_modes) pragma from
a bunch of files. I'll put it back!

+ mode still has to be used in a few places for functions that get
moved (see task.rs)

The changes outside core and std are due to the to_bytes trait and
making the compiler (with legacy modes on) agree with the libraries
(with legacy modes off) about modes.
2012-10-02 14:31:39 -07:00
Graydon Hoare
e480e19694 Attempt to fix option::test_unwrap_str breakage. 2012-10-01 16:14:30 -07:00
Graydon Hoare
1229d1c2ce De-export option and option_iter. Part of #3583. 2012-10-01 14:12:36 -07:00
Tim Chevalier
3639d38d5c Add a demoded version of ptr::addr_of
Currently, the new version is ptr::p2::addr_of and the old one is
ptr::addr_of. This is kind of cheesy, but I need a snapshot before I
can ditch the old version, since the pipe compiler generates calls to
addr_of.

core is converted over to use the new version, std is not.
2012-09-28 22:19:01 -07:00
Brian Anderson
8766c2e35b core: Demode patterns 2012-09-28 16:57:36 -07:00
Brian Anderson
438bdd687b core: More option demoding 2012-09-27 17:49:10 -07:00
Brian Anderson
e8fe718bfd core: Replace map/map_default with map_ref/map_default_ref 2012-09-26 20:15:23 -07:00
Brian Anderson
62649f0412 Check more things with deprecated_modes 2012-09-25 17:41:29 -07:00
Brian Anderson
afd91f8a56 Register snapshots. Remove redundant Eq impls, Makefile hacks 2012-09-23 23:01:49 -07:00
Brian Anderson
4a78f9b166 core: Demode option 2012-09-23 17:15:00 -07:00
Niko Matsakis
ba3eebd41d Make it illegal to use modes in a fn signature with providing
an explicit variable name. (Step one to changing the defaults)

First step to #3535
2012-09-23 13:30:13 -05:00
Patrick Walton
9117dcb968 rustc: De-mode all overloaded operators 2012-09-20 09:48:05 -07:00
Tim Chevalier
c087886e93 Make moves explicit in arguments 2012-09-11 20:02:34 -07:00
Tim Chevalier
a07ea73bdb Make moves explicit in task; also make option::unwrap take its argument by move 2012-09-10 13:36:54 -07:00
Tim Chevalier
e666fe89dd Make more moves explicit in libcore 2012-09-10 12:38:52 -07:00
Brian Anderson
3bd1f32cd9 Convert all kind bounds to camel case. Remove send, owned keywords. 2012-09-07 18:10:11 -07:00
Brian Anderson
2572e80355 Remove 'let' syntax for struct fields 2012-09-07 14:02:33 -07:00
Patrick Walton
feb014eb3c rustc: Add an "ne" method to the Eq trait, and implement it everywhere 2012-09-07 12:24:48 -07:00
Brian Anderson
02b1c32e4d core: Remove struct ctors 2012-09-04 15:46:33 -07:00
Brian Anderson
117aa8cfee core: warn(non_camel_case_types) everywhere, with few exceptions 2012-09-02 16:14:26 -07:00
Patrick Walton
5792244d03 rustc: Implement equality for option types 2012-08-27 17:24:50 -07:00
Brian Anderson
8337fa1a54 Camel case the option type 2012-08-26 15:56:16 -07:00
Ben Blum
6cf2f89452 Implement option::unwrap safely...! 2012-08-25 03:07:30 -04:00
Niko Matsakis
652b312122 more sound treatment of fn& regions; change all & to be distinct 2012-08-21 10:28:34 -07:00
Daniel Patterson
62ea688e50 core: adding option::or, a function to return the leftmost of two some() values or none if both are none 2012-08-20 21:29:41 -04:00
Brian Anderson
3ab4b014cf Remove the class keyword 2012-08-17 10:13:45 -07:00
Ben Blum
0e3825d38c Add option::get_ref 2012-08-16 21:07:55 -04:00
Ben Blum
4377802202 De-mode task.rs and add some option::foo_ref() helpers 2012-08-14 19:32:52 -04:00