Commit graph

104 commits

Author SHA1 Message Date
Paul Stansifer
29f32b4a72 m1!{...} -> m1!(...) 2012-08-23 11:14:14 -07:00
Niko Matsakis
511e7626ae Infer variance of types with respect to the region parameter.
A similar approach could be used for type parameters.

Fixes #2282.
2012-08-23 06:30:43 -07:00
Tim Chevalier
c8ce32e7f4 Represent "item families" in the decoder as an enum
This eliminates some match checks. Also get rid of other match checks
in metadata code.
2012-08-22 20:32:09 -07:00
Tim Chevalier
1b804ce343 Merge find_linkage_attrs with find_linkage_metas
This gets rid of a gratuitous `match check`.
2012-08-22 16:43:23 -07:00
Paul Stansifer
1153b5dcc8 intern identifiers 2012-08-22 14:59:25 -07:00
Patrick Walton
9ea6b3a32e rustc: Remove a few allocations from metadata. Shaves a few milliseconds off compilation of hello world. 2012-08-17 15:54:18 -07:00
Patrick Walton
f79006937a rustc: Remove tag_paths and all of the associated encoding 2012-08-17 15:23:44 -07:00
Patrick Walton
8f01343f01 rustc: Remove resolve_path 2012-08-17 15:07:14 -07:00
Patrick Walton
75d3e3c755 rustc: Remove a user of tag_paths.
This commit breaks the item-printing functionality. It will return in a faster
form.
2012-08-17 14:55:52 -07:00
Patrick Walton
578b7266f2 rustc: Encode reexports in the metadata and don't have each_path search tag_paths 2012-08-17 12:42:45 -07:00
Brian Anderson
3ab4b014cf Remove the class keyword 2012-08-17 10:13:45 -07:00
Patrick Walton
3038968f28 rustc: Perform some AST surgery to separate out class fields from methods 2012-08-15 16:20:35 -07:00
Brian Anderson
74c69e1053 Convert more core types to camel case 2012-08-15 14:14:20 -07:00
Brian Anderson
11258310e2 Convert more core types to camel case 2012-08-14 18:26:03 -07:00
Michael Sullivan
e640a66eb4 Make most forms of explicit self work. By-value not implemented. Work on #2585. 2012-08-14 17:40:04 -07:00
Brian Anderson
6a0720b439 Convert impls to new syntax 2012-08-08 18:19:24 -07:00
Michael Sullivan
76d04af71a In decoder, rename class_member_id to item_def_id. 2012-08-08 12:01:19 -07:00
Michael Sullivan
7f7f47620e Implement static typeclass methods. Closes #3132. 2012-08-07 17:18:14 -07:00
Brian Anderson
ecaf9e39c9 Convert alt to match. Stop parsing alt 2012-08-06 15:36:30 -07:00
Brian Anderson
025d86624d Switch alts to use arrows 2012-08-05 22:08:09 -07:00
Patrick Walton
a805a1fb37 rustc: Add the notion of inherited visibility 2012-08-03 15:02:53 -07:00
Niko Matsakis
97452c0ca1 Remove modes from map API and replace with regions.
API is (for now) mostly by value, there are options to use it by
reference if you like.  Hash and equality functions must be pure
and by reference (forward looking to the day when something
like send_map becomes the standard map).
2012-08-02 15:53:28 -07:00
Brian Anderson
b355936b4d Convert ret to return 2012-08-01 19:16:06 -07:00
Patrick Walton
2cfe8fb357 rustc: Check self types in method lookup; allow required trait methods to have self types; write self types into metadata 2012-07-31 16:35:11 -07:00
Paul Stansifer
a9cc5066ee Change syntax extension syntax: #m[...] -> m!{...}. 2012-07-30 18:38:15 -07:00
Eric Holk
65beca4e01 Use iteration protocol for ebml, use vec::view in more places (issue #2880) 2012-07-26 17:10:48 -07:00
Patrick Walton
afd9a75c9e rustc: Fix cross-crate max/min-class-style constructors 2012-07-26 15:30:15 -07:00
Patrick Walton
da80bd17c3 rustc: Introduce a lang_items pass, part of coherence and operator overloading.
This will also help us remove kinds.
2012-07-25 18:37:03 -07:00
Patrick Walton
57e8de8917 rustc: Implement multiple-traits-per-impl for cross-crate stuff 2012-07-18 17:34:59 -07:00
Patrick Walton
1528256fdc rustc: Encode metadata unconditionally for impls/traits/classes. Closes #2945. 2012-07-18 14:43:16 -07:00
Patrick Walton
db020ab63c rustc: Implement and enforce instance coherence 2012-07-17 15:46:43 -07:00
Michael Sullivan
92743dc2a6 Move the world over to using the new style string literals and types. Closes #2907. 2012-07-14 01:03:43 -07:00
Michael Sullivan
985b52be6d Support prefix notation for vstore strings. Closes #2906. 2012-07-13 17:03:49 -07:00
Eric Holk
aba665da32 Fix the signature on vec::view.
Due to limitations in region inference, this has the effect of making vec::view pretty much entirely unusable.
2012-07-12 18:16:00 -07:00
Michael Sullivan
2ea9c8df0f Accept prefix notation for writing the types of str/~ and friends. 2012-07-12 16:52:26 -07:00
Niko Matsakis
b9aa9def85 infer when types are region parameterized rather than requiring /&
- removes various fields from various variants in the AST
- also update tests not to use this notation
2012-07-11 14:41:41 -07:00
Patrick Walton
6912b11089 rustc: Fix the collision with Tim's change 2012-07-09 17:44:15 -07:00
Tim Chevalier
271da617cb Tag re-exports differently in metadata
so that the "list metadata" command doesn't print out anything
about intrinsics, but other code can see them.

Closes #2771
2012-07-09 15:21:29 -07:00
Josh Matthews
a7f6e00944 Fix metadata serialization of foreign functions. Properly take the value of foreign functions from other crates to fix #1840. 2012-07-09 13:13:49 -07:00
Lindsey Kuper
33334f3c43 Change 'iface' to 'trait' internally; parse trait as iface synonym 2012-07-05 11:01:43 -07:00
Gareth Daniel Smith
be0141666d convert doc-attributes to doc-comments using ./src/etc/sugarise-doc-comments.py (and manually tweaking) - for issue #2498 2012-07-04 19:18:13 -07:00
Patrick Walton
dbbffbea9a rustc: Make a note of the fact that each_path doesn't handle path nesting properly 2012-07-03 18:32:47 -07:00
Patrick Walton
af38333f75 rustc: Speed up def ID parsing in the metadata 2012-07-03 17:12:02 -07:00
Patrick Walton
742c05f87d rustc: Avoid a lot of copying in metadata when reading impls 2012-07-03 16:38:35 -07:00
Graydon Hoare
debb7e4641 Switch 'native' to 'extern' (or 'foreign' in some descriptions) 2012-07-03 16:11:00 -07:00
Patrick Walton
f093d374ed rustc: Implement a new resolve pass behind a compile flag 2012-07-02 18:30:12 -07:00
Brian Anderson
569467eb0d Merge remote-tracking branch 'Dretch/prettydocs'
Conflicts:
	src/compiletest/errors.rs
	src/libsyntax/parse/attr.rs
	src/libsyntax/parse/comments.rs
	src/test/compile-fail/ambig_impl_unify.rs
	src/test/compile-fail/assign-super.rs
	src/test/compile-fail/bad-for-loop.rs
	src/test/compile-fail/bad-var-env-capture-in-block-arg.rs
	src/test/compile-fail/block-arg-as-stmt-with-value.rs
	src/test/compile-fail/borrowck-assign-comp-idx.rs
	src/test/compile-fail/borrowck-lend-flow.rs
	src/test/compile-fail/borrowck-loan-blocks-move-cc.rs
	src/test/compile-fail/borrowck-loan-blocks-mut-uniq.rs
	src/test/compile-fail/borrowck-loan-rcvr.rs
	src/test/compile-fail/borrowck-loan-vec-content.rs
	src/test/compile-fail/borrowck-mut-vec-as-imm-slice-bad.rs
	src/test/compile-fail/cap-clause-with-stack-closure.rs
	src/test/compile-fail/do1.rs
	src/test/compile-fail/do2.rs
	src/test/compile-fail/empty-vec-trailing-comma.rs
	src/test/compile-fail/evec-subtyping.rs
	src/test/compile-fail/issue-1896.rs
	src/test/compile-fail/issue-2149.rs
	src/test/compile-fail/issue-2150.rs
	src/test/compile-fail/issue-2487-b.rs
	src/test/compile-fail/kindck-implicit-close-over-mut-var.rs
	src/test/compile-fail/liveness-issue-2163.rs
	src/test/compile-fail/liveness-use-in-index-lvalue.rs
	src/test/compile-fail/no-reuse-move-arc.rs
	src/test/compile-fail/no-send-res-ports.rs
	src/test/compile-fail/non-const.rs
	src/test/compile-fail/pure-higher-order.rs
	src/test/compile-fail/pure-loop-body.rs
	src/test/compile-fail/regions-addr-of-upvar-self.rs
	src/test/compile-fail/regions-escape-loop-via-vec.rs
	src/test/compile-fail/regions-scoping.rs
	src/test/compile-fail/seq-args.rs
	src/test/compile-fail/tstate-unsat-in-called-fn-expr.rs
	src/test/compile-fail/tstate-unsat-in-fn-expr.rs
	src/test/compile-fail/vec-add.rs
	src/test/compile-fail/vec-concat-bug.rs
	src/test/compile-fail/vector-no-ann.rs
2012-07-02 15:23:41 -07:00
Brian Anderson
d1fc2b5995 Convert to new closure syntax 2012-07-01 19:19:32 -07:00
Brian Anderson
a3382b6f26 Eliminate usages of old sugared call syntax 2012-06-30 16:01:49 -07:00
Gareth Daniel Smith
0b653ab953 initial draft of fix for issue #2498:
1. make /// ... and //! ... and /** ... */ and /*! ... */ into sugar for #[doc = ...] attributes.
2. add a script in etc/ to help converting doc-attributes to doc-comments
3. add some functions to core::str to help with (1)
2012-06-30 11:54:54 +01:00