Commit Graph

4481 Commits

Author SHA1 Message Date
Rafael Ávila de Espíndola
a355505a5f Fix line length. 2011-06-20 17:57:29 -04:00
Marijn Haverbeke
56eb986584 Fix some uses of span_warn in alias.rs that should be span_fatal 2011-06-20 23:53:29 +02:00
Marijn Haverbeke
588dc3897b Make trans use the new ast_map instead of building its own 2011-06-20 23:53:28 +02:00
Marijn Haverbeke
854b3a9b73 Use ast_map in typeck, instead of building another index 2011-06-20 23:53:28 +02:00
Marijn Haverbeke
40db3aa6fb Add a separate AST mapping phase
This will replace the various node_id-to-node mappings done in several
other passes. This commit already uses the new map in resolve, dropping
the ast_map that was built there before.
2011-06-20 23:53:28 +02:00
Marijn Haverbeke
77af54bf6f Reduce confusing variable naming in resolve
'id' is now used for node_ids, 'name' for idents
2011-06-20 23:53:28 +02:00
Marijn Haverbeke
75681f9ad7 Get rid of def_ids and anns in AST nodes, use single node_id
This reduces some redundancy in the AST data structures and cruft in
the code that works with them. To get a def_id from a node_id, apply
ast::local_def, which adds the local crate_num to the given node_id.
Most code only deals with crate-local node_ids, and won't have to
create def_ids at all.
2011-06-20 23:53:28 +02:00
Rafael Ávila de Espíndola
3d8a5cb9e6 Remember the library files we used in rustc and pass them to the "linker".
This avoid the hardcoded -lstd, allows programs to use other crates and avoids
any differences that may exist in the rustc and ld search logic.
2011-06-20 17:44:12 -04:00
Eric Holk
a2dcd08cc2 Added string duplication to deep_copy. Closes #520. 2011-06-20 13:47:02 -07:00
Graydon Hoare
c051501784 Tighten up the hardbreak rules a bit. 2011-06-20 19:58:23 +00:00
Graydon Hoare
8cd0695230 Suppress hardbreaks when following hardbreaks. 2011-06-20 19:58:23 +00:00
Graydon Hoare
035d60d533 Fix interference between if-check and if printing. 2011-06-20 19:58:23 +00:00
Graydon Hoare
1ad8efa86e Fix 'reformat' mk target to handle recent libdir changes. 2011-06-20 19:58:23 +00:00
Eric Holk
992153672b Removed duplicated ret_ty_of_fn. This also means the native function branch is working now, so this commit closes #506. 2011-06-20 12:04:33 -07:00
Eric Holk
ce50ae3212 Added a test case for #506 2011-06-20 12:04:33 -07:00
Eric Holk
5640bead58 Teach ret_ty_of_fn_ty to understand native functions. Closes #506. 2011-06-20 12:04:33 -07:00
Rafael Ávila de Espíndola
283744ba78 Remove flags that are not used during linking. 2011-06-20 15:00:07 -04:00
Rafael Ávila de Espíndola
164230dcb6 Finish the transition to having the std library in stageN/lib. 2011-06-20 13:38:11 -04:00
Graydon Hoare
97cf57adc1 Fix pp blank-lines insertion at beginning of file and before 'let' decls. 2011-06-20 10:45:33 -04:00
Brian Anderson
200dbe4c4f Remove various rustboot workarounds 2011-06-19 20:48:20 -07:00
Graydon Hoare
9b6ae59b22 Fix pp blank-line insertion after isolated comments in cboxes. 2011-06-19 22:55:58 -04:00
Patrick Walton
3f7380ccec rustc: Change smallintmap to use an ivec and use it for the node type table. 3x typechecking speedup. 2011-06-19 18:03:19 -07:00
Patrick Walton
8cdef277b2 rt: Fix size miscalculation in ivec_reserve 2011-06-19 18:03:19 -07:00
Brian Anderson
6cf9b17086 rustc: Make name resolution errors less fatal
Failure happens at the end of name resolution

Issue #440
2011-06-19 15:23:11 -07:00
Brian Anderson
c5238d57eb rustc: Make import resolution errors less fatal
Failure happens at the end of import resolution

Issue #440
2011-06-19 14:35:50 -07:00
Brian Anderson
76a752e7a4 rustc: Export only what's needed from middle::ty
The list is formidable.
2011-06-19 12:27:43 -07:00
Brian Anderson
80a8af7b47 rustc: Export only what's used from middle::resolve 2011-06-19 12:27:43 -07:00
Brian Anderson
942fcbe7a1 rustc: Re-introduce session.span_err, session.err
These errors are non-fatal. The session.abort_if_errors function needs to be
called at strategic points to convert the previous errors to utter failure.

Issue #440
2011-06-19 12:19:53 -07:00
Brian Anderson
43427dae0c rustc: Rename session.span_err -> span_fatal, err -> fatal
Issue #440
2011-06-19 12:19:53 -07:00
Brian Anderson
cf9ed08a50 Revert previous 6 commits. Hopefully put out Windows fire.
Revert "rustc: Export only what's needed from middle::ty"

This reverts commit 4255d58aa5.

Revert "rustc: Make name resolution errors less fatal"

This reverts commit b8ab9ea89c.

Revert "rustc: Make import resolution errors less fatal"

This reverts commit 92a8ae94b9.

Revert "rustc: Export only what's used from middle::resolve"

This reverts commit 4539a2cf7a.

Revert "rustc: Re-introduce session.span_err, session.err"

This reverts commit 7fe9a88e31.

Revert "rustc: Rename session.span_err -> span_fatal, err -> fatal"

This reverts commit c394a7f49a.
2011-06-19 03:29:19 -07:00
Brian Anderson
4255d58aa5 rustc: Export only what's needed from middle::ty
The list is formidable.
2011-06-19 02:42:05 -07:00
Brian Anderson
b8ab9ea89c rustc: Make name resolution errors less fatal
Failure happens at the end of name resolution

Issue #440
2011-06-19 02:42:05 -07:00
Brian Anderson
92a8ae94b9 rustc: Make import resolution errors less fatal
Failure happens at the end of import resolution

Issue #440
2011-06-19 02:42:01 -07:00
Brian Anderson
4539a2cf7a rustc: Export only what's used from middle::resolve 2011-06-19 02:41:03 -07:00
Brian Anderson
7fe9a88e31 rustc: Re-introduce session.span_err, session.err
These errors are non-fatal. The session.abort_if_errors function needs to be
called at strategic points to convert the previous errors to utter failure.

Issue #440
2011-06-19 02:41:02 -07:00
Brian Anderson
c394a7f49a rustc: Rename session.span_err -> span_fatal, err -> fatal
Issue #440
2011-06-19 02:40:59 -07:00
Brian Anderson
514813148b rustc: Store the lhs and rhs of receive exprs in left to right order
With the changing of receive semantics the parser has been putting the rhs
expression in the first argument of expr_recv and the lhs in the second, and
all subsequent passes have been referring to them backwords (but still doing
the right thing because they were assuming that lhs was the port and rhs was
the receiver).

This makes all code agree on what lhs and rhs mean for receive expressions.
2011-06-18 20:23:05 -07:00
Brian Anderson
364cd5763c rustc: receive is spelled |> now 2011-06-18 20:23:05 -07:00
Brian Anderson
3852f1eee3 Typecheck block tail expressions that are fn return values 2011-06-18 20:23:05 -07:00
Brian Anderson
2752284f4b Add TIME_LLVM_PASSES flag to the Makefile 2011-06-18 20:23:05 -07:00
Brian Anderson
7d1979d024 Add FIXMEs to meta documentation
Issue #487
2011-06-18 20:23:05 -07:00
Brian Anderson
ddbb31eb8e rustc: Remove the meta keyword
Issue #487
2011-06-18 20:23:05 -07:00
Brian Anderson
f58de2d687 Replace unexported meta tags with attributes
Issue #487
2011-06-18 20:23:05 -07:00
Brian Anderson
60023047a4 rustc: Replace 'export meta' with attributes
Issue #487
2011-06-18 20:23:05 -07:00
Graydon Hoare
814beaafdf Add -lssp on windows in attempt to put out tinderbox; no idea why ssp seems required on mingw. 2011-06-18 22:07:02 -04:00
Patrick Walton
7bb6733f2c test: Add a test case for derived-tydescs-before-dynamic-allocas 2011-06-18 18:44:21 -07:00
Patrick Walton
4f13879218 rustc: Allocate derived tydescs before dynamically sized allocas 2011-06-18 18:43:07 -07:00
Patrick Walton
877f001512 rustc: Don't bother to supply an alignment argument to the memmove intrinsic; LLVM is very fussy about what it considers a constant. 2011-06-18 16:59:44 -07:00
Patrick Walton
ca2ff9c50d stdlib: Add ivec::grow_set() 2011-06-18 16:41:09 -07:00
Patrick Walton
5d90b1df4b stdlib: Add ivec::grow() and ivec::grow_fn() 2011-06-18 16:29:45 -07:00