]> git.lizzy.rs Git - rust.git/log
rust.git
12 years agoUpdate llvm and integrate clang and compiler-rt.
Graydon Hoare [Mon, 30 Apr 2012 22:40:04 +0000 (15:40 -0700)]
Update llvm and integrate clang and compiler-rt.

12 years agocore: Move global_env mod into os mod
Brian Anderson [Tue, 1 May 2012 00:42:41 +0000 (17:42 -0700)]
core: Move global_env mod into os mod

12 years agocore: Serialize all access to the environment using a weak global task
Brian Anderson [Tue, 1 May 2012 00:28:14 +0000 (17:28 -0700)]
core: Serialize all access to the environment using a weak global task

12 years agobuild: No tidy for test files. Closes #2271
Brian Anderson [Mon, 30 Apr 2012 23:32:47 +0000 (16:32 -0700)]
build: No tidy for test files. Closes #2271

12 years agoAnnotate FIXME (comment only)
Tim Chevalier [Mon, 30 Apr 2012 21:17:32 +0000 (14:17 -0700)]
Annotate FIXME (comment only)

12 years agoRevert "Eliminate a copy in syntax::parse::new_parser_from_file"
Tim Chevalier [Mon, 30 Apr 2012 18:52:07 +0000 (11:52 -0700)]
Revert "Eliminate a copy in syntax::parse::new_parser_from_file"

This reverts commit 2bb3b63ec4379b812aeceb690d78763ec55d3cbb.

(I was confused.)

12 years agoEliminate a copy in syntax::parse::new_parser_from_file
Tim Chevalier [Fri, 27 Apr 2012 21:21:17 +0000 (14:21 -0700)]
Eliminate a copy in syntax::parse::new_parser_from_file

Fixing a FIXME turned out to be pretty involved. I added an io function
that returns a unique boxed string (for the contents of a file) rather than
a string, and went from there. Also made the src field of codemap a unique
boxed string. This doesn't seem to make that much difference in amount of
allocation according to valgrind (disappointingly), but I also had to introduce
a copy somewhere else pending a new snapshot, so maybe that's it.

12 years agorustc: Use a slightly more consistent style for unexpected errors
Brian Anderson [Sat, 28 Apr 2012 23:38:06 +0000 (16:38 -0700)]
rustc: Use a slightly more consistent style for unexpected errors

12 years agostd: Add 2 timer stress tests
Brian Anderson [Sat, 28 Apr 2012 21:13:25 +0000 (14:13 -0700)]
std: Add 2 timer stress tests

12 years agort/std: whitespace cleanup + work on hl/global_loop docs
Jeff Olson [Sat, 28 Apr 2012 05:19:20 +0000 (22:19 -0700)]
rt/std: whitespace cleanup + work on hl/global_loop docs

12 years agostd: another stab at a race-free global loop implementation
Jeff Olson [Sat, 28 Apr 2012 04:42:04 +0000 (21:42 -0700)]
std: another stab at a race-free global loop implementation

seems to hold up pretty well.

uv::hl API is affected.. had to do work on tests and std::timer code that
leverages the global loop/high_level_loop API.

see test_stress_gl_uv_global_loop_high_level_global_timer for a stress
example.. it takes a while to run, but it exits cleanly (something I could
never accomplish with earlier iterations of the global loop)

12 years agort: remove unneccesary c++ functions and rust_kernel data, re: global loop
Jeff Olson [Sat, 28 Apr 2012 04:39:45 +0000 (21:39 -0700)]
rt: remove unneccesary c++ functions and rust_kernel data, re: global loop

12 years agostd: get rid of some un-needed rustrt native fns for the global loop
Jeff Olson [Sat, 28 Apr 2012 04:38:48 +0000 (21:38 -0700)]
std: get rid of some un-needed rustrt native fns for the global loop

12 years agostd: add ll::loop_refcount binding for uv_loop_refcount
Jeff Olson [Sat, 28 Apr 2012 04:01:31 +0000 (21:01 -0700)]
std: add ll::loop_refcount binding for uv_loop_refcount

12 years agonew, simpler approach to the iter library
Niko Matsakis [Thu, 12 Apr 2012 04:45:18 +0000 (21:45 -0700)]
new, simpler approach to the iter library

12 years agoparser: More refactoring of restricted value name checking
Brian Anderson [Fri, 27 Apr 2012 22:44:40 +0000 (15:44 -0700)]
parser: More refactoring of restricted value name checking

12 years agoparser: Remove a restricted keyword check
Brian Anderson [Fri, 27 Apr 2012 22:16:53 +0000 (15:16 -0700)]
parser: Remove a restricted keyword check

I can't find a way to trigger this error

12 years agotest: Add test for two restricted keyword cases
Brian Anderson [Fri, 27 Apr 2012 22:03:30 +0000 (15:03 -0700)]
test: Add test for two restricted keyword cases

12 years agoparser: Make parse_value_path use parse_value_ident
Brian Anderson [Fri, 27 Apr 2012 19:35:04 +0000 (12:35 -0700)]
parser: Make parse_value_path use parse_value_ident

12 years agoparser: Rewrite parse_path_without_tps so it knows beforehand which is the last ident
Brian Anderson [Fri, 27 Apr 2012 19:22:42 +0000 (12:22 -0700)]
parser: Rewrite parse_path_without_tps so it knows beforehand which is the last ident

Needed to centralize all keyword-as-value parsing in parse_value_ident

12 years agoparser: Fix lookahead of > 1 token
Brian Anderson [Fri, 27 Apr 2012 19:19:52 +0000 (12:19 -0700)]
parser: Fix lookahead of > 1 token

12 years agosyntax: Refactor ident parsing
Brian Anderson [Fri, 27 Apr 2012 01:35:16 +0000 (18:35 -0700)]
syntax: Refactor ident parsing

12 years agorustc: Remove old align_of intrinsic
Brian Anderson [Fri, 27 Apr 2012 22:40:40 +0000 (15:40 -0700)]
rustc: Remove old align_of intrinsic

12 years agoRegister snapshots
Brian Anderson [Fri, 27 Apr 2012 21:37:09 +0000 (14:37 -0700)]
Register snapshots

12 years agocompiletest: Unbreak on Win32
Brian Anderson [Fri, 27 Apr 2012 18:55:13 +0000 (11:55 -0700)]
compiletest: Unbreak on Win32

12 years agorustc: Clean up some enum code
Brian Anderson [Thu, 26 Apr 2012 00:06:01 +0000 (17:06 -0700)]
rustc: Clean up some enum code

12 years agocore: Add os::arch. Exposes target_arch string at runtime
Brian Anderson [Fri, 27 Apr 2012 08:36:22 +0000 (01:36 -0700)]
core: Add os::arch. Exposes target_arch string at runtime

12 years agotest: Enable an assert in run-pass/rec-align-32-bit.rs
Brian Anderson [Fri, 27 Apr 2012 06:39:44 +0000 (23:39 -0700)]
test: Enable an assert in run-pass/rec-align-32-bit.rs

12 years agocore: Split sys::align_of into min_align_of, pref_align_of
Brian Anderson [Fri, 27 Apr 2012 05:28:03 +0000 (22:28 -0700)]
core: Split sys::align_of into min_align_of, pref_align_of

12 years agorustc: Add min_align_of, pref_align_of intrinsic, deprecate align_of
Brian Anderson [Fri, 27 Apr 2012 05:21:28 +0000 (22:21 -0700)]
rustc: Add min_align_of, pref_align_of intrinsic, deprecate align_of

12 years agorustc: Add llalign_of_min
Brian Anderson [Fri, 27 Apr 2012 04:52:55 +0000 (21:52 -0700)]
rustc: Add llalign_of_min

12 years agorustc: Rename llalign_of_real to llalign_of_pref
Brian Anderson [Fri, 27 Apr 2012 04:44:27 +0000 (21:44 -0700)]
rustc: Rename llalign_of_real to llalign_of_pref

This alignment is the "preferred" alignment of a type, which is not
necessarily the alignment the compiler will use when packing the
type into structures - that is the "ABI" alignment (in LLVM terms).

On x86, 64-bit ints have 8-byte preferred alignment, but 4-byte
ABI alignment.

12 years agorustc: Add LLVM bindings for more alignment-related functions
Brian Anderson [Fri, 27 Apr 2012 04:33:38 +0000 (21:33 -0700)]
rustc: Add LLVM bindings for more alignment-related functions

12 years agotest: xfail-win32 run-pass/rec-align-32-bit.rs
Brian Anderson [Fri, 27 Apr 2012 02:55:57 +0000 (19:55 -0700)]
test: xfail-win32 run-pass/rec-align-32-bit.rs

12 years agort: Fix shape alignment of 64-bit ints on x86. Issue #2303
Brian Anderson [Fri, 27 Apr 2012 00:49:38 +0000 (17:49 -0700)]
rt: Fix shape alignment of 64-bit ints on x86. Issue #2303

12 years agoRefactor operator precedence code
Tim Chevalier [Thu, 26 Apr 2012 23:13:59 +0000 (16:13 -0700)]
Refactor operator precedence code

Use functions instead of a dynamically created table to determine
operator precedence. Gets rid of a FIXME in syntax::parse::prec.
Change precedences from int to uint while we're at it, since
don't use negative precedences.

12 years agoAdd check for path-statements, close #400.
Graydon Hoare [Thu, 26 Apr 2012 20:47:13 +0000 (13:47 -0700)]
Add check for path-statements, close #400.

12 years agoLowercase warning message.
Graydon Hoare [Thu, 26 Apr 2012 20:27:05 +0000 (13:27 -0700)]
Lowercase warning message.

12 years agoDescribe warnings on command line if user says -W help.
Graydon Hoare [Thu, 26 Apr 2012 20:26:45 +0000 (13:26 -0700)]
Describe warnings on command line if user says -W help.

12 years agostd: Add FIXME about time tests
Brian Anderson [Thu, 26 Apr 2012 20:54:01 +0000 (13:54 -0700)]
std: Add FIXME about time tests

12 years agotemporary hack to make testing std::time reliable
Ted Horst [Fri, 20 Apr 2012 06:29:13 +0000 (01:29 -0500)]
temporary hack to make testing std::time reliable

12 years agolots of work to make iface/impls parameterized by regions
Niko Matsakis [Tue, 24 Apr 2012 22:52:52 +0000 (15:52 -0700)]
lots of work to make iface/impls parameterized by regions

- paths can now take region parameters, replacing the dirty hack
  I was doing before of abusing vstores.  vstores are now a bit
  of a hack though.

- fix various small bugs:
  - we never checked that iface types were compatible when casting
    to an iface with `as`
  - we allowed nonsense like int<int>
  - and more! (actually that may be it)

12 years agoBe a bit more cautious about marking things no-throw.
Graydon Hoare [Thu, 26 Apr 2012 01:53:54 +0000 (18:53 -0700)]
Be a bit more cautious about marking things no-throw.

12 years agoMore slice use in vec, io, str, ebml, metadata encoder and decoder.
Graydon Hoare [Thu, 26 Apr 2012 00:18:06 +0000 (17:18 -0700)]
More slice use in vec, io, str, ebml, metadata encoder and decoder.

12 years agoSet no-unwind on glue functions that don't drop resources.
Graydon Hoare [Thu, 26 Apr 2012 00:18:34 +0000 (17:18 -0700)]
Set no-unwind on glue functions that don't drop resources.

12 years agoSet no-unwind attribute on all upcalls other than fail.
Graydon Hoare [Wed, 25 Apr 2012 22:38:56 +0000 (15:38 -0700)]
Set no-unwind attribute on all upcalls other than fail.

12 years agoRegister snapshots.
Graydon Hoare [Tue, 24 Apr 2012 22:51:42 +0000 (15:51 -0700)]
Register snapshots.

12 years agotest: Fix run-pass/enum-mach-type-compat on x86
Brian Anderson [Wed, 25 Apr 2012 23:06:57 +0000 (16:06 -0700)]
test: Fix run-pass/enum-mach-type-compat on x86

12 years agotest: Fix and un-xfail run-pass/use
Brian Anderson [Wed, 25 Apr 2012 22:58:33 +0000 (15:58 -0700)]
test: Fix and un-xfail run-pass/use

12 years agotest: Remove run-pass/user.rs. Old test for unimplemented feature
Brian Anderson [Wed, 25 Apr 2012 22:56:21 +0000 (15:56 -0700)]
test: Remove run-pass/user.rs. Old test for unimplemented feature

12 years agorustc: Cache normalized types
Brian Anderson [Wed, 25 Apr 2012 01:23:54 +0000 (18:23 -0700)]
rustc: Cache normalized types

12 years agorustc: Use LLVM named structs for enum types
Brian Anderson [Mon, 23 Apr 2012 23:01:03 +0000 (16:01 -0700)]
rustc: Use LLVM named structs for enum types

12 years agotypeck: Take more care to pass down expected types
Marijn Haverbeke [Wed, 25 Apr 2012 15:40:18 +0000 (17:40 +0200)]
typeck: Take more care to pass down expected types

This helps with prototype inference and avoids some 'must be known
in this context' errors.

12 years agoRegister new snapshot
Marijn Haverbeke [Wed, 25 Apr 2012 10:57:08 +0000 (12:57 +0200)]
Register new snapshot

(With the fix for #2185 included.)

12 years agoRewrite exhaustiveness checker
Marijn Haverbeke [Tue, 24 Apr 2012 09:13:25 +0000 (11:13 +0200)]
Rewrite exhaustiveness checker

Issue #2111

12 years agosyntax: Divide keywords into contextual/restricted. No bad words
Brian Anderson [Wed, 25 Apr 2012 05:33:49 +0000 (22:33 -0700)]
syntax: Divide keywords into contextual/restricted. No bad words

12 years agosyntax: Make 'true' and 'false' bad words
Brian Anderson [Wed, 25 Apr 2012 04:47:22 +0000 (21:47 -0700)]
syntax: Make 'true' and 'false' bad words

When these are idents they are always shadowed by the boolean
constants.

12 years agosyntax: Clean up the bad_expr_word functions
Brian Anderson [Wed, 25 Apr 2012 04:05:25 +0000 (21:05 -0700)]
syntax: Clean up the bad_expr_word functions

12 years agosyntax: Rename is_word to is_keyword, etc.
Brian Anderson [Wed, 25 Apr 2012 03:16:53 +0000 (20:16 -0700)]
syntax: Rename is_word to is_keyword, etc.

12 years agoRevert "rustc: Use LLVM named structs for enum types"
Brian Anderson [Wed, 25 Apr 2012 03:47:06 +0000 (20:47 -0700)]
Revert "rustc: Use LLVM named structs for enum types"

This reverts commit 6e909e387d1b71a8b813433ce834384ffb13fedf.

12 years agoRevert "rustc: Cache normalized types"
Brian Anderson [Wed, 25 Apr 2012 03:47:00 +0000 (20:47 -0700)]
Revert "rustc: Cache normalized types"

This reverts commit 06afe21c033abf370825034f3b1639a80386da6d.

12 years agorustc: Cache normalized types
Brian Anderson [Wed, 25 Apr 2012 01:23:54 +0000 (18:23 -0700)]
rustc: Cache normalized types

12 years agorustc: Use LLVM named structs for enum types
Brian Anderson [Mon, 23 Apr 2012 23:01:03 +0000 (16:01 -0700)]
rustc: Use LLVM named structs for enum types

12 years agoWorkarounds for bug #2280: add some temporaries for borrowing.
Graydon Hoare [Tue, 24 Apr 2012 22:18:24 +0000 (15:18 -0700)]
Workarounds for bug #2280: add some temporaries for borrowing.

12 years agorustc: Fix type_need_unwind_cleanup. Closes #2272
Brian Anderson [Tue, 24 Apr 2012 21:16:50 +0000 (14:16 -0700)]
rustc: Fix type_need_unwind_cleanup. Closes #2272

12 years agorustc: Remove a bitcast. Issue #2276
Brian Anderson [Tue, 24 Apr 2012 21:00:43 +0000 (14:00 -0700)]
rustc: Remove a bitcast. Issue #2276

12 years agobuild: Don't require full target libs to run compiletest tests
Brian Anderson [Tue, 24 Apr 2012 20:30:00 +0000 (13:30 -0700)]
build: Don't require full target libs to run compiletest tests

Only build through librustsyntax, which some tests do rely on.

12 years agoAdd a cross-crate test for casting classes to ifaces
Tim Chevalier [Tue, 24 Apr 2012 17:35:10 +0000 (10:35 -0700)]
Add a cross-crate test for casting classes to ifaces

12 years agorustc: Eliminate trans dependency from metadata::tyencode
Brian Anderson [Tue, 24 Apr 2012 06:40:53 +0000 (23:40 -0700)]
rustc: Eliminate trans dependency from metadata::tyencode

12 years agoAllow classes to be cast to ifaces that are in the same crate
Tim Chevalier [Fri, 13 Apr 2012 19:22:35 +0000 (12:22 -0700)]
Allow classes to be cast to ifaces that are in the same crate

I had to xfail one existing test case (class-implements-int) because,
I think, of the same bug described in #2272.

12 years agoRename option::get_or_default to get_default, for consistency
Tim Chevalier [Wed, 11 Apr 2012 16:24:46 +0000 (09:24 -0700)]
Rename option::get_or_default to get_default, for consistency

12 years agoExplain difference between star and underscore in patterns in the reference manual
Tim Chevalier [Tue, 24 Apr 2012 02:22:24 +0000 (19:22 -0700)]
Explain difference between star and underscore in patterns in the reference manual

12 years agoencode the borrowing table, add a simple cross-crate borrowing test
Niko Matsakis [Mon, 23 Apr 2012 22:23:20 +0000 (15:23 -0700)]
encode the borrowing table, add a simple cross-crate borrowing test

12 years agoFix bug with * patterns in trans_alt
Tim Chevalier [Mon, 23 Apr 2012 22:50:51 +0000 (15:50 -0700)]
Fix bug with * patterns in trans_alt

    enter_opt was handling the (*) case wrong and causing a bounds check
    failure. Fixed it (the test case is one of the extracted ones from
    the reference manual)

12 years agoMention lazy evaluation of log arguments in tutorial
Tim Chevalier [Mon, 23 Apr 2012 22:50:40 +0000 (15:50 -0700)]
Mention lazy evaluation of log arguments in tutorial

12 years agoDiscuss (*) patterns in reference documentation
Tim Chevalier [Mon, 23 Apr 2012 22:50:16 +0000 (15:50 -0700)]
Discuss (*) patterns in reference documentation

12 years agoRegister snapshots.
Graydon Hoare [Mon, 23 Apr 2012 19:13:56 +0000 (12:13 -0700)]
Register snapshots.

12 years agomoderate comment, remove some dead regions code
Niko Matsakis [Sat, 21 Apr 2012 17:26:51 +0000 (10:26 -0700)]
moderate comment, remove some dead regions code

12 years agoremove dead code
Niko Matsakis [Sat, 21 Apr 2012 17:17:10 +0000 (10:17 -0700)]
remove dead code

12 years agoremove outdated comment
Niko Matsakis [Sat, 21 Apr 2012 17:13:15 +0000 (10:13 -0700)]
remove outdated comment

12 years agoVarious regions fixes.
Niko Matsakis [Sat, 21 Apr 2012 17:04:58 +0000 (10:04 -0700)]
Various regions fixes.

12 years agorewrite the resolution infrastructure; but it's still grody
Niko Matsakis [Fri, 20 Apr 2012 22:46:57 +0000 (15:46 -0700)]
rewrite the resolution infrastructure; but it's still grody

12 years agoGuard against infinitely expanding generic/inline functions
Marijn Haverbeke [Mon, 23 Apr 2012 14:44:52 +0000 (16:44 +0200)]
Guard against infinitely expanding generic/inline functions

Closes #2220

Test case disabled until a memory-leak issue is resolved.

12 years agoEmit a more useful error when using an unsuitable function for a loop
Marijn Haverbeke [Mon, 23 Apr 2012 13:43:29 +0000 (15:43 +0200)]
Emit a more useful error when using an unsuitable function for a loop

Closes #2255

12 years agoMove map iface over to more `for`-friendly iteration methods
Marijn Haverbeke [Mon, 23 Apr 2012 11:42:15 +0000 (13:42 +0200)]
Move map iface over to more `for`-friendly iteration methods

12 years agoSimplify representation of ast::path
Marijn Haverbeke [Mon, 23 Apr 2012 11:04:46 +0000 (13:04 +0200)]
Simplify representation of ast::path

12 years agoMisc code cleanups using list::each for list iteration
Marijn Haverbeke [Mon, 23 Apr 2012 10:10:06 +0000 (12:10 +0200)]
Misc code cleanups using list::each for list iteration

12 years agopretty printer: Properly print explicity types for block params
Marijn Haverbeke [Mon, 23 Apr 2012 08:27:09 +0000 (10:27 +0200)]
pretty printer: Properly print explicity types for block params

12 years agoFix long line in test
Marijn Haverbeke [Mon, 23 Apr 2012 07:54:27 +0000 (09:54 +0200)]
Fix long line in test

12 years agoFix broken determination of external method type param count
Marijn Haverbeke [Mon, 23 Apr 2012 07:25:14 +0000 (09:25 +0200)]
Fix broken determination of external method type param count

Closes #2185

12 years agosyntax: Replace token::DOLLAR_PAREN, DOLLAR_NUM with just DOLLAR
Brian Anderson [Sun, 22 Apr 2012 23:58:04 +0000 (16:58 -0700)]
syntax: Replace token::DOLLAR_PAREN, DOLLAR_NUM with just DOLLAR

Figure the rest out in the parser

12 years agosyntax: Eliminate token::POUND_LT, POUND_LBRACE
Brian Anderson [Sun, 22 Apr 2012 22:15:18 +0000 (15:15 -0700)]
syntax: Eliminate token::POUND_LT, POUND_LBRACE

Use lookahead in the parser

12 years agosyntax: Move is_lit to mod token
Brian Anderson [Sun, 22 Apr 2012 21:59:04 +0000 (14:59 -0700)]
syntax: Move is_lit to mod token

12 years agosyntax: Remove unused BRACEQUOTE, IDX, LIT_BOOL tokens
Brian Anderson [Sun, 22 Apr 2012 21:54:19 +0000 (14:54 -0700)]
syntax: Remove unused BRACEQUOTE, IDX, LIT_BOOL tokens

12 years agocargo: Discover crates in subdirectories
Brian Anderson [Sat, 21 Apr 2012 22:46:05 +0000 (15:46 -0700)]
cargo: Discover crates in subdirectories

12 years agocore: Add os::walk_dir
Brian Anderson [Sat, 21 Apr 2012 22:45:51 +0000 (15:45 -0700)]
core: Add os::walk_dir

12 years agosyntax: Eliminate 'mutable' keyword. Closes #2254
Brian Anderson [Sat, 21 Apr 2012 20:42:54 +0000 (13:42 -0700)]
syntax: Eliminate 'mutable' keyword. Closes #2254

12 years agorustc: Cache constant C strings. Closes #2264
Brian Anderson [Sat, 21 Apr 2012 20:23:25 +0000 (13:23 -0700)]
rustc: Cache constant C strings. Closes #2264

12 years agostd: Export sort::le
Brian Anderson [Sat, 21 Apr 2012 20:45:20 +0000 (13:45 -0700)]
std: Export sort::le

12 years agoPrint out return type correctly in typestate error message
Tim Chevalier [Sat, 21 Apr 2012 01:47:01 +0000 (18:47 -0700)]
Print out return type correctly in typestate error message

In the "not all paths return" error message, typestate was printing
the AST type from the fn decl, not the ty::t type. This ended in tears
when the AST return type was "ty_infer". Now it looks up the function node
ID's type and uses util::ppaux::ty_to_str instead.

Closes #2163.