Commit Graph

99 Commits

Author SHA1 Message Date
Alex Crichton 92d39fe4d5 syntax: Remove #[allow(vecs_implicitly_copyable)] 2013-05-14 12:24:43 -04:00
Björn Steinbrink bdc182cc41 Use static string with fail!() and remove fail!(fmt!())
fail!() used to require owned strings but can handle static strings
now. Also, it can pass its arguments to fmt!() on its own, no need for
the caller to call fmt!() itself.
2013-05-14 16:36:23 +02:00
Tim Chevalier ed41864464 Warning police 2013-05-11 20:36:44 -07:00
John Clements 41af279233 parser comments 2013-04-28 09:51:16 -07:00
Daniel Micay f792baba42 only use #[no_core] in libcore 2013-04-27 21:34:24 -04:00
Alex Crichton fd97cac251 syntax: remove unused 'mut' variables 2013-04-20 21:03:24 -04:00
Alex Crichton 3c7aea3a6a syntax: de-mode and prepare for de-modeing rustc 2013-04-19 23:21:52 -04:00
Patrick Walton 1e91595520 librustc: Remove fail_unless! 2013-03-29 16:39:08 -07:00
Alex Crichton be57d745d2 Removing unused imports 2013-03-28 23:56:46 -04:00
Andrew Paseltiner f02ee42a86 derive Eq and Clone impls where applicable 2013-03-27 22:04:23 -04:00
Marvin Löbel b9de2b5787 Switched over a bunch of splitting funktions to non-allocating iterators 2013-03-26 14:59:17 +01:00
Patrick Walton e7c60c141b librustc: Remove pure from libsyntax and librustc. 2013-03-22 12:57:27 -07:00
Marvin Löbel 0a47cd5ef1 Un-renamed trim and substr functions. 2013-03-21 23:06:05 +01:00
Marvin Löbel ee2f3d9673 Switched over substr and trim functions in str to be non-allocating, temporary renamed them to better track use-sites 2013-03-21 23:06:04 +01:00
Marvin Löbel 9d9a209e9a back-renamed slice_DBG_BRWD, slice_V_DBG_BRWD -> slice, slice_DBG_UNIQ -> slice_unique 2013-03-21 14:05:57 +01:00
Marvin Löbel a7d296f24c renamed str::view -> slice_DBG_BRWD
renamed str::slice -> slice_DBG_UNIQ
changed vec slice method -> to_owned()
renamed vec view method  -> slice_V_DBG_BRWD
2013-03-21 01:50:32 +01:00
Alex Crichton cd7f3ad22e syntax: Removing some bad copies 2013-03-20 00:33:15 -04:00
Patrick Walton b1c699815d librustc: Don't accept as Trait anymore; fix all occurrences of it. 2013-03-13 20:07:09 -07:00
Brian Anderson 82f190355b Remove uses of log 2013-03-11 23:19:42 -07:00
Patrick Walton d7e74b5e91 librustc: Convert all uses of assert over to fail_unless! 2013-03-07 22:37:57 -08:00
Alex Crichton dfb5c10dea Remove unused imports throughout src/ 2013-03-04 12:27:01 -05:00
Erick Tryzelaar 4ae91e2961 libsyntax: add explicit copies 2013-02-26 20:48:11 -08:00
Erick Tryzelaar ff36986fa4 libsyntax: change token fns to take &Token 2013-02-26 01:51:41 -08:00
Erick Tryzelaar d346b51997 libsyntax: change token::to_str to take &Token 2013-02-26 01:29:27 -08:00
Luqman Aden b02f5c2090 Get rid of structural records in libsyntax and the last bit in librustc. 2013-02-21 00:19:15 -08:00
Erick Tryzelaar e6d84268fa Change functions from taking ~str to taking &str 2013-02-19 10:02:51 -08:00
bors bf27352953 auto merge of #4911 : lifthrasiir/rust/comment-exemptions, r=catamorphism
This is a natural extension of #4887, and handles the following three cases:

~~~~
a line with only /s
////////////////////////////////////////////

a line with only /s followed by whitespace
////////////////////////////////////////////         

a block comment with only *s between two /s
/********************************/
~~~~
2013-02-14 16:34:38 -08:00
Patrick Walton 9143688197 librustc: Replace impl Type : Trait with impl Trait for Type. rs=implflipping 2013-02-14 14:44:12 -08:00
Nick Desaulniers 4445b38df2 Remove die!, raplace invocations with fail! Issue #4524 pt 3 2013-02-13 17:01:32 -08:00
Kang Seonghoon 6d98ca94cc libsyntax: don't parse ////, /***/ as doc comments 2013-02-13 11:39:13 +09:00
Patrick Walton 472797b04a librustc: Lots of de-muting. rs=demuting 2013-02-07 16:17:39 -08:00
John Clements 53688addaa test cases, cleanup 2013-01-31 23:05:12 -08:00
Nick Desaulniers aee7929469 Replace most invocations of fail keyword with die! macro 2013-01-31 20:12:49 -08:00
Patrick Walton 95b892c8a7 libsyntax: De-export a lot of libsyntax. rs=deëxporting 2013-01-29 13:55:30 -08:00
Patrick Walton eb4d39e1fe libstd: Remove "dual impls" from the language and enforce coherence rules. r=brson
"Dual impls" are impls that are both type implementations and trait
implementations. They can lead to ambiguity and so this patch removes them
from the language.

This also enforces coherence rules. Without this patch, records can implement
traits not defined in the current crate. This patch fixes this, and updates
all of rustc to adhere to the new enforcement. Most of this patch is fixing
rustc to obey the coherence rules, which involves converting a bunch of records
to structs.
2013-01-29 10:42:45 -08:00
Patrick Walton f405e41d7a librustc: Implement write guards for borrowing @mut to & or &mut. r=nmatsakis 2013-01-17 11:50:20 -08:00
Patrick Walton 2db3abddcd librustc: Make unqualified identifier searches terminate at the nearest module scope. r=tjc 2013-01-08 22:02:35 -08:00
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
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
Patrick Walton 4c2e4c37ce librustc: Make use statements crate-relative by default. r=brson 2012-12-13 13:05:22 -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 4a5b28ff0c Stop tracking CodeMap offsets in the parse session. Big simplification 2012-11-16 14:22:09 -08:00
Brian Anderson 2374154ded Stop storing char positions in CodeMap 2012-11-16 14:10:17 -08:00
Brian Anderson 81d20156cd Change spans to use byte offsets instead of char offsets 2012-11-16 12:06:44 -08:00
Brian Anderson 4a0f4f5e31 Refactor the lexer to use FilePos types 2012-11-15 14:24:53 -08:00
Brian Anderson 8069d2f266 Track character and byte positions together in the parser 2012-11-14 16:34:50 -08:00