Commit Graph

6899 Commits

Author SHA1 Message Date
Brian Anderson
4699b6865f build: Use llvm-mc as our assembler
LLVM's assembler understands .cfi pseudo-ops on the mac, which we need in
order to generate frames that can be DWARF-unwound
2011-12-10 18:51:21 -08:00
Austin Seipp
638b51488f Disable unused features in the LLVM build.
Issue #1274 - should make the build a wee bit faster.
2011-12-09 19:27:18 -08:00
Elly Jones
f05eaa4a65 cargo: support github:<user>/<repo> 2011-12-09 14:21:21 -08:00
Elly Jones
0acf170c9f cargo: support git:// URIs. 2011-12-09 14:21:21 -08:00
Elly Jones
b53e4e8463 cargo: don't stick an extra / in CARGO_ROOT 2011-12-09 14:21:21 -08:00
Elly Jones
7b0c73d8fa cargo: refactor a bit 2011-12-09 14:21:21 -08:00
Elly Jones
7f945eeae9 cargo: support installing crates
Introduce the notion of CARGO_ROOT to override HOME if need be. Build packages
there instead of in /tmp. Install to CARGO_ROOT/bin and CARGO_ROOT/lib.
2011-12-09 14:21:21 -08:00
Erick Tryzelaar
e3a066bde8 Swap arg order for option::{may,maybe}
This lets us write the block syntax sugar:

option::may(x) { |y| … }
2011-12-09 10:22:24 -08:00
Marijn Haverbeke
44ffd8e3aa Allow type annotations for blocks
I.e. {|foo: int| -> int foo + 2}

Issue #1275
2011-12-09 09:42:22 +01:00
Brian Anderson
54f72fbc10 rustc: Actually hook the crate_type attribute into session 2011-12-08 21:31:50 -08:00
Brian Anderson
4f17131855 Add crate_type attributes to rustc, std, core 2011-12-08 21:09:48 -08:00
Brian Anderson
9116a6d9b1 rustc: Support 'crate_type' attribute
[crate_type = "lib"] builds it as a library.
[crate_type = "bin"] builds it as an executable.

Executable is the default. --lib and --bin switches override.
2011-12-08 21:09:15 -08:00
Brian Anderson
6156295a4c rustc: Move linking into compile_input 2011-12-08 20:33:31 -08:00
Brian Anderson
fd81fb6a24 rustc: Determine the crate type (lib/bin) in the session, not session opts
This is in preparation for adding a #[crate_type] attribute
2011-12-08 20:08:00 -08:00
Brian Anderson
9e6ff44d93 rt: Make __morestack work on win32 2011-12-08 16:47:33 -08:00
Marijn Haverbeke
0e74121ddb Error when parsing the empty record type
Issue #1200
2011-12-08 13:29:43 +01:00
Marijn Haverbeke
9a269a3aa8 Allow binding of nested patterns
See src/test/run-pass/nested-patterns.rs for some examples. The syntax is

    boundvar@subpattern

Which will match the subpattern as usual, but also bind boundvar to the
whole matched value.

Closes #838
2011-12-08 12:03:48 +01:00
Marijn Haverbeke
8c966b7b18 Stop passing around some unused information in typeck 2011-12-08 10:53:04 +01:00
Marijn Haverbeke
a7c6cb7385 Consider variant constructors pure functions for the purpose of purity checking
Closes #1269
2011-12-08 10:26:42 +01:00
Brian Anderson
94b0fee6f1 rt: Reorganize and add documentation for rust_upcall.cpp 2011-12-07 18:50:23 -08:00
Brian Anderson
31fe5d0bd8 rt: Run most upcalls on the C stack 2011-12-07 18:50:23 -08:00
Niko Matsakis
0fc4403442 use util::rational to work around bug w/ floats on win 2011-12-07 17:05:58 -08:00
Niko Matsakis
1ff8994fce Purge old map impl: more collisions, not clear it is safe on 64bit 2011-12-07 17:05:58 -08:00
Niko Matsakis
4b704ac69b improve comments 2011-12-07 17:05:58 -08:00
Niko Matsakis
ed0e13f1d8 fix old map impl, add logging 2011-12-07 17:05:58 -08:00
Niko Matsakis
30a2361e68 add some debugging logs 2011-12-07 17:05:58 -08:00
Niko Matsakis
13a3288f3f dec size in remove 2011-12-07 17:05:58 -08:00
Niko Matsakis
ddfe82a466 make rehashing more efficient by not re-allocating entries 2011-12-07 17:05:58 -08:00
Niko Matsakis
729345cb97 implement a chained hashmap 2011-12-07 17:05:58 -08:00
Graydon Hoare
501c514e89 Register new snapshots (containing libcore auto-importing it now). 2011-12-07 16:36:56 -08:00
Graydon Hoare
3ccdd2a098 Mention new dirs in README. 2011-12-07 15:34:30 -08:00
Graydon Hoare
e4aa73c0f9 Change snapshot script to pick up host libcore as well. 2011-12-07 15:34:16 -08:00
Brian Anderson
81f932e7d7 rt: Fix alignment of stacks generated by __morestack 2011-12-07 14:06:46 -08:00
Graydon Hoare
e056ffa17d Inject the view_items for core in the right place, add comment documenting why the wrong place was wrong. 2011-12-07 13:33:00 -08:00
Graydon Hoare
799690bea0 Remove stmt_crate_directive, it's vestigial and confusing. 2011-12-07 13:33:00 -08:00
Graydon Hoare
dfd699a852 Pass --no-core when building libcore. 2011-12-07 13:32:59 -08:00
Marijn Haverbeke
17e99ec57f Fix test that used an oversized int literal 2011-12-07 22:10:56 +01:00
Marijn Haverbeke
7548a0d77a Restore accidentally overwritten test 2011-12-07 22:02:38 +01:00
Marijn Haverbeke
3d0610b072 Check for literals that are out of range for their type 2011-12-07 21:53:05 +01:00
Marijn Haverbeke
e3eca9174b Change literal representation to not truncate
Also shuffles around the organization of numeric literals and types,
separating by int/uint/float instead of machine-vs-non-machine types.
This simplifies some code.

Closes #974
Closes #1252
2011-12-07 21:08:28 +01:00
Graydon Hoare
6daa233a73 Register new snapshots. 2011-12-07 11:57:48 -08:00
Graydon Hoare
a3f48d3fe1 Merge branch 'master' of github.com:graydon/rust 2011-12-07 11:52:38 -08:00
Niko Matsakis
6c95e400d8 repair more hash functions 2011-12-07 07:35:25 -08:00
Marijn Haverbeke
03a6e54212 Disallow binding by-mut-ref and by-move arguments
Fix bug in bound by-copy arguments.

Closes #1261
2011-12-07 15:28:57 +01:00
Marijn Haverbeke
d28e0c0c0a Make typestate properly descend pattern guards
Closes #1265
2011-12-07 14:09:45 +01:00
Brian Anderson
9656ceac60 rt: Put 16 guard bytes at the end of the stack 2011-12-06 22:35:42 -08:00
Brian Anderson
5d1a1dc420 rt: Rename stk_seg.limit to stk_seg.end
rust_task is using the word limit it two ways, so one has to change.
2011-12-06 21:45:53 -08:00
Brian Anderson
3d7b89bc4d rt: Reorganize rust_upcall.cpp a bit 2011-12-06 21:44:19 -08:00
Brian Anderson
00636e3155 rt: Convert log_type and cmp_type upcalls to shim form 2011-12-06 21:44:19 -08:00
Brian Anderson
c11d0b0aa0 rt: Move upcall_cmp_type/upcall_log_type to rust_upcall.cpp 2011-12-06 21:44:18 -08:00