Brian Anderson
91e5a1c8b3
core: Remove the nearly empty math module
...
This mod only had two functions, all of whose users have been changed
to use the uint module.
2012-03-10 17:43:19 -08:00
Tim Chevalier
d048a00cf3
Change util::unreachable to core::unreachable
...
Closes #1931
2012-03-08 14:30:01 -08:00
Erick Tryzelaar
3cb2cd1f71
comp/fuzzer: rewrite to use io::with_str_reader.
2012-03-02 19:15:35 -08:00
Erick Tryzelaar
f630ebdb6a
comp/std: rename io::string_reader to io::str_reader.
2012-03-02 19:15:35 -08:00
Jesse Ruderman
8e4c5d2d4d
Start next_id at 1 to make the compiler happy
2012-02-24 20:25:54 -08:00
Jesse Ruderman
e5521aa03e
AST fuzzer: remove ignores for fixed issues; update issue URLs
2012-02-24 19:52:56 -08:00
Jesse Ruderman
f455dc1976
Improve the cycle-collector fuzzer
2012-02-24 19:26:42 -08:00
Marijn Haverbeke
0f00d9a797
Adjust fuzzer and cargo to changes in core::str API
2012-02-23 17:11:21 +01:00
Kevin Cantu
7782f5d692
(core::str) remove len_bytes alias
2012-02-23 17:00:19 +01:00
Kevin Cantu
280633a728
(core::str) do some replacements
2012-02-23 17:00:19 +01:00
Kevin Cantu
454b53a7c2
(core::char) rename slice -> slice_chars
2012-02-23 17:00:19 +01:00
Kevin Cantu
1cd5a0945a
(core::str) rename rindex -> rindex_chars
2012-02-23 17:00:19 +01:00
Kevin Cantu
98447f5236
(core::str) mostly rename len -> len_chars
2012-02-23 17:00:19 +01:00
Niko Matsakis
bfff2a8d55
make mut a keyword synonymous with mutable
...
first step towards issue #1273
2012-02-15 13:26:11 -08:00
Marijn Haverbeke
9e685005d4
Fix use of expr_alt in fuzzer that was causing the build to fail
2012-02-15 12:01:09 +01:00
Kevin Cantu
c81867474a
(core::str) add find_bytes and export it...
2012-02-13 01:56:58 -08:00
Kevin Cantu
2b4f5136a5
(core::str) rename byte_len -> len_bytes and rename char_len -> len
2012-02-12 15:30:20 -08:00
Kevin Cantu
e0af23b664
using str::rindex...
2012-02-11 16:39:39 -08:00
Kevin Cantu
a131b430a0
core::str rename [r]index -> [r]index_bytes
2012-02-11 16:39:39 -08:00
Kevin Cantu
8f367ebfeb
Rename (again) str::unsafe::slice -> str::unsafe::slice_bytes and
...
str::unsafe::safe_slice -> str::unsafe::slice_bytes_safe_range
2012-02-01 21:56:53 -08:00
Kevin Cantu
47c57a17dc
Propagating unsafe::slice 1
2012-02-01 21:56:53 -08:00
Kevin Atkinson
c5e03e0e59
Keep source file around after parsing.
...
Specifically box the string (to avoid unnecessary copies) and store it
in codemap::filemap.
Remove the hack in driver::diagnostic that rereads the source from the
file and instead just get the source from the filemap.
(This commit is also a prerequisite for issue #1612 )
2012-01-25 16:00:47 -07:00
Patrick Walton
9ecd5ee81d
rustc: Split diagnostics into "span diagnostics" and "diagnostics".
...
The former contain a codemap (which is per-crate), and the latter don't. This
will be useful in order to allow more than one crate to be compiled in one run
of the compiler.
2012-01-24 21:42:54 -08:00
Niko Matsakis
5e13d19cc0
s/block()/fn()/g
2012-01-23 19:06:33 -08:00
Kevin Atkinson
20ab47fe49
Allow ast_fold_precursor to change the span.
...
This involved changing the prototype for the callbacks to thread the
span though. A wrapper function, fold::wrap, can be used to wrap the
old style callbacks.
2012-01-23 17:37:15 -08:00
Kevin Atkinson
ad21d9c64a
Don't reset the chpos/byte_pos to 0 in new_parser_from_source_str.
...
This correctly fixes issue #1362 .
chpos/byte_pos are now the offsets within a particular file, but
rather the offsets within a virtual file with is formed by combing all
of the modules within a crate. Thus, resetting them to 0 causes an
overlap and hence, bogus source locations.
Fix #1362 by moving chpos/byte_pos to parse_sess so that
new_parser_from_source_str has access to them and hence can chose an
initial value that is not already been used in the crate.
Note that the trigger for bug 1361 was that syntax/ext/expand.rs calls
parse_expr_from_source_str (which calls new_parser_from_source_str)
using the same codemap as the current crate (and hence causing overlap
with files in the crate as new_parser_from_source_str resets the
chpos/byte_pos to 0).
2012-01-23 17:37:15 -08:00
Patrick Walton
d1fe582040
misc: ';' to ',' in enums in cargo, compiletest, and fuzzer
2012-01-19 18:47:30 -08:00
Patrick Walton
035b56d8aa
misc: "tag" -> "enum" for cargo, compiletest, fuzzer, rustdoc
2012-01-19 16:21:33 -08:00
Tim Chevalier
5b028f527f
Remove support for the '.' after a nullary tag in a pattern
...
(Commit also includes lots of changes to remove '.'s that a git
merge messed up, or else it was monkeys.)
2012-01-19 01:04:59 -08:00
Tim Chevalier
04a2887f87
Remove '.' after nullary tags in patterns
...
Does what it says on the tin.
The next commit will remove support for this syntax.
2012-01-18 23:17:34 -08:00
Brian Anderson
c0df13958c
Update crates with correct crate_type attribute
2012-01-17 15:13:43 -08:00
Brian Anderson
8f57be5bff
rustc: Rename mk_codemap_handler to mk_handler
2012-01-14 15:14:43 -08:00
Brian Anderson
e4849d5e5d
rustc: Allow a custom diagnostic emitter when building the handler
2012-01-14 15:14:43 -08:00
Brian Anderson
eb41fd9021
Update tools for new parser API
2012-01-13 22:07:55 -08:00
Niko Matsakis
8685a1f7c4
distinguish "any closure" and "stack closure" (block)
2012-01-13 09:31:40 -08:00
Marijn Haverbeke
34d7f05292
Major clean-up of std::io
...
Use ifaces instead of objs, stop wrapping everything in two (or three)
layers of no-value-added indirection, and remove some of the more
pointless/outdated idioms from the code.
2012-01-11 21:00:11 +01:00
Jesse Ruderman
972f6c17fb
Fix bustage
2012-01-08 19:34:02 -08:00
Jesse Ruderman
159ad7a63b
Update fuzzer
2012-01-08 19:24:24 -08:00
Jesse Ruderman
bf038b9b90
Get these files compiling again
2012-01-06 22:06:32 -08:00
Stefan Plantikow
c8467977c4
Merge branch 'master' into kmath
...
Conflicts:
src/libcore/float.rs
2012-01-05 17:20:13 +01:00
Stefan Plantikow
1f10ee365c
Moved generic float::min, max to core::math and cleaned up some imports
2012-01-05 17:11:34 +01:00
Marijn Haverbeke
60ae1590af
Switch to new param kind bound syntax
...
And remove support for the old syntax
2012-01-05 15:50:02 +01:00
Graydon Hoare
f0dfbe7b1b
Register new snapshots, purge log_err and log_full in favour of log(...).
2011-12-22 17:53:53 -08:00
Graydon Hoare
389329ef1e
Merge all 3 log syntaxes, tidy up residual misuses.
2011-12-22 16:14:00 -08:00
Graydon Hoare
8b580954fe
Register snapshots and switch logging over to use of log_full or #error / #debug.
2011-12-22 14:42:52 -08:00
Stefan Plantikow
b957916e06
removed math leftovers from std
2011-12-20 18:07:36 +01:00
Elly Jones
89e880d613
std: file_is_dir -> path_is_dir, add path_exists
2011-12-16 17:37:21 -05:00
Niko Matsakis
2833ca478c
reorder args to the various vec, option fns so blk comes last
2011-12-16 07:17:23 -08:00
Graydon Hoare
fa9ad984fb
Copy first batch of material from libstd to libcore.
2011-12-13 16:34:50 -08:00
Marijn Haverbeke
f6491bb426
Update stdlib, compiler, and tests to new kind system
...
This involved adding 'copy' to more generics than I hoped, but an
experiment with making it implicit showed that that way lies madness --
unless enforced, you will not remember to mark functions that don't
copy as not requiring copyable kind.
Issue #1177
2011-11-18 12:49:01 +01:00
Niko Matsakis
adc79e2f44
remove compile-command from local variable blocks
2011-11-17 11:46:13 -08:00
Haitao Li
5a7249c935
Cleanup unused imports
2011-11-10 19:19:40 -08:00
Brian Anderson
e0f44730e8
rustc: Support 'companion mod's for crates and directory mods
...
Under this scheme when parsing foo.rc the parser will also look for
foo.rs to fill in the crate-level module, and when evaluating a
directory module directive it will look for a .rs file with the
same name as the directory.
2011-10-29 01:40:20 -07:00
Brian Anderson
2cebef095e
stdlib: Make io failures recoverable by returning a result
2011-10-29 01:25:11 -07:00
Matt Brubeck
5d6fe1a533
Remove uint::max/min in favor if math::max/min
2011-10-27 13:37:53 -07:00
Marijn Haverbeke
cfdf193c46
Update our code to new type parameter kind syntax
...
Closes #1067
2011-10-25 15:56:55 +02:00
Marijn Haverbeke
3b5b93221e
Remove some semicolons after block calls
...
The remaining ones can be removed after the next snapshot. (Or
we can let the next pretty-print pass take care of them.)
2011-10-21 14:24:42 +02:00
Marijn Haverbeke
0ce40f60e7
Drop support for iter, put, and for-each
...
Closes #1056
2011-10-21 13:47:24 +02:00
Marijn Haverbeke
050170d2af
Remove remaining uses of iter and for-each
...
Issue #1056
2011-10-21 13:34:35 +02:00
Brian Anderson
29ad3bdb10
Make fn denote a bare function. Convert fn to fn@ as needed
2011-10-20 18:23:48 -07:00
Brian Anderson
459353e107
Prevent copies of resources into various things
2011-09-27 21:50:07 -07:00
Jesse Ruderman
4ff46a1502
Add a cycle-collection fuzzer
2011-09-26 20:34:07 -07:00
Jesse Ruderman
203bc16e7b
Fuzzer: stop ignoring fixed bugs
2011-09-25 12:24:42 -07:00
Jesse Ruderman
2b15aefffe
Fuzzer: ignore more bugs
2011-09-24 21:01:39 -07:00
Jesse Ruderman
fbe00fc236
Add rand_util.rs
2011-09-23 23:24:43 -07:00
Jesse Ruderman
3bac3378ae
Fuzzer: use different exclusions when testing pretty-printer than when testing compiler
2011-09-23 23:23:04 -07:00
Jesse Ruderman
35016d3147
Ignore #949
2011-09-20 16:42:58 -07:00
Jesse Ruderman
571ff0c84a
Add @true to common_exprs and fix some exclusions
2011-09-20 16:32:27 -07:00
Jesse Ruderman
d882f8ee2f
Fuzzer: add common_exprs, but comment out its use for now. Update lists of known bugs.
2011-09-20 12:04:12 -07:00
Jesse Ruderman
58d812f0f8
Fix syntax error
2011-09-20 11:58:33 -07:00
Jesse Ruderman
35873a95d4
Fuzzer: add ability to run the generated programs
2011-09-19 21:57:43 -07:00
Brian Anderson
b1bf9ef5ae
Break fold's circular reference during unwinding
...
This converts the AST fold into a resource that breaks it's own circular
reference (just a temporary workaround until GC), so that failure during fold
will unwind correctly.
Issue #936
2011-09-19 15:32:56 -07:00
Jesse Ruderman
72317dee0d
Fuzzer: update lists of known bugs
2011-09-16 10:44:58 -07:00
Graydon Hoare
a4815b6742
Factor imports mindlessly.
2011-09-12 16:13:28 -07:00
Marijn Haverbeke
ca1df2b111
Pretty-print for new arg-mode syntax
2011-09-12 12:49:00 +02:00
Marijn Haverbeke
fc6b7c8b38
Reformat for new mode syntax, step 1
...
Long lines were fixed in a very crude way, as I'll be following up
with another reformat in a bit.
2011-09-12 12:04:14 +02:00
Jesse Ruderman
476bbca87a
Fuzzer: move tys around in addition to exprs
2011-09-10 18:55:09 -07:00
Jesse Ruderman
8df7c2b0d4
Fuzzer: first steps of making steal_exprs more generic
2011-09-10 14:51:33 -07:00
Jesse Ruderman
cdf30c2b29
ivec_fuzz: use vec::reversed
2011-09-10 12:12:44 -07:00
Jesse Ruderman
9245228f94
ivec_fuzz: remove obsolete comments
2011-09-10 12:03:13 -07:00
Jesse Ruderman
fe4227df04
ivec_fuzz: require shared types, because that's what vec::slide requires
2011-09-10 12:02:24 -07:00
Jesse Ruderman
5ef27245b1
Fuzzer: Refactor check_whole_compiler so it doesn't halt the fuzzer when it finds a bug.
2011-09-10 00:51:07 -07:00
Jesse Ruderman
8e1902f30f
Fuzzer: update lists of known bugs
2011-09-09 22:31:26 -07:00
Jesse Ruderman
ce432d4cf9
Fuzzer: remove exclusions for some issues that have been fixed
2011-09-09 17:31:08 -07:00
Brian Anderson
5c49e4f4e9
Reformat. Issue #855
2011-09-02 22:11:42 -07:00
Brian Anderson
9c173f17c0
Remove lots of estr code from rustc. Issue #855
2011-09-01 23:25:33 -07:00
Brian Anderson
418d09e547
Convert all uses of #ifmt to #fmt. Issue #855
2011-09-01 18:54:03 -07:00
Brian Anderson
ab6bb035e5
Rename std::istr to std::str. Issue #855
2011-09-01 17:27:58 -07:00
Brian Anderson
e824775d53
Remove std::str. Issue #855
2011-09-01 16:09:15 -07:00
Brian Anderson
bb56a75343
Convert main functions to istrs. Issue #855
2011-09-01 12:14:35 -07:00
Brian Anderson
04700066f3
Convert fuzzer to istrs. Issue #855
2011-08-31 16:24:08 -07:00
Brian Anderson
81b31429e4
Remove more uses of str from std::run. Issue #855
2011-08-31 16:24:08 -07:00
Brian Anderson
498e38b705
Convert uses of #fmt to #ifmt. Issue #855
2011-08-31 11:44:06 -07:00
Marijn Haverbeke
6209e844ee
Replace xfail-stageN with simply xfail-test
...
Closes #799
2011-08-31 16:32:16 +02:00
Brian Anderson
cbad23a747
Convert pretty-printer to istrs. Issue #855
2011-08-27 15:54:46 -07:00
Brian Anderson
675073c266
Convert parser to istrs. Issue #855
2011-08-27 15:54:46 -07:00
Brian Anderson
fcc031c5b4
Convert std::io to istrs. Issue #855
2011-08-27 15:54:43 -07:00
Brian Anderson
20178b9312
Convert std::run to istrs. Issue #855
2011-08-27 15:53:09 -07:00
Brian Anderson
c2eafd268b
Convert std::fs to istrs. Issue #855
2011-08-27 15:53:09 -07:00
Brian Anderson
518dc52f85
Reformat
...
This changes the indexing syntax from .() to [], the vector syntax from ~[] to
[] and the extension syntax from #fmt() to #fmt[]
2011-08-20 11:04:00 -07:00