Patrick Walton
1048f9abfa
rustc: Factor out struct literal typechecking in preparation for struct-like enum variants
2012-10-22 18:00:55 -07:00
Patrick Walton
ec1c60c4d6
rustc: Implement generic cross-crate trait inheritance
2012-10-22 18:00:48 -07:00
Brian Anderson
5a86f5d084
rustc: Convert two printlns in trans into debug!
2012-10-22 13:33:44 -07:00
Brian Anderson
64e1ecb939
Long lines
2012-10-22 12:02:55 -07:00
Brian Anderson
2eea07be11
Merge pull request #3826 from jdm/doublefail
...
Fix ICE stemming from use of unique pointers in unreachable blocks.
2012-10-22 11:32:30 -07:00
Tim Chevalier
14e7df7d1a
Fix breakage (forgot to commit this...
2012-10-22 10:54:23 -07:00
Tim Chevalier
dca0776747
Incorporate review comments (mostly fixing indentation)
...
Previous commit was r=nmatsakis
2012-10-22 09:44:56 -07:00
Tim Chevalier
dd66e7549b
Preliminary support for labeled break/continue for loop
s
...
This patch adds preliminary middle-end support (liveness and trans)
for breaks and `loop`s to `loop` constructs that have labels.
while and for loops can't have labels yet.
Progress on #2216
2012-10-22 09:20:37 -07:00
Tim Chevalier
46d4bbbae4
Simplify the AST representation of ty param bounds
...
Change ast::ty_param_bound so that all ty param bounds are represented
as traits, with no special cases for Copy/Send/Owned/Const.
typeck::collect generates the special cases.
A consequence of this is that code using the #[no_core] attribute
can't use the Copy kind/trait. Probably not a big deal?
As a side effect, any user-defined traits that happen to be called
Copy, etc. in the same module override the built-in Copy trait.
r=nmatsakis
Closes #2284
2012-10-22 09:01:12 -07:00
Niko Matsakis
42c05fe642
Correct propagation of mutability from components to base in borrowck
...
Fixes #3828 .
2012-10-21 23:52:36 -07:00
Josh Matthews
7c7980196c
Fix ICE stemming from use of unique pointers in unreachable blocks.
2012-10-21 03:43:41 -04:00
Ben Striegel
ac81fff229
Remove old fixed-length vector syntax
2012-10-20 17:50:46 -07:00
Tim Chevalier
10612ee30c
Remove superfluous by-ref in option::get, option::get_default, option::expect
...
Superficial change, no review.
2012-10-19 11:38:28 -07:00
Patrick Walton
754704ea94
rustc: Implement intra-crate static methods on anonymous trait implementations. r=nmatsakis
2012-10-18 14:29:18 -07:00
Erick Tryzelaar
a7ecde3323
libcore: minor code cleanup.
...
This is minor and probably completely inconsequential to performance,
but I find vec::map to be more clear than vec::each and a push.
2012-10-18 10:09:57 -07:00
Erick Tryzelaar
95423d28f2
libcore: call [u8] values bytes, not bufs
2012-10-18 10:09:42 -07:00
Erick Tryzelaar
4e03ffdb65
rustc: optimize away some mallocs when building GEP args
2012-10-18 08:03:04 -07:00
Tim Chevalier
33adb7a824
Merge pull request #3739 from killerswan/usagemsg
...
Add a module to getopts for verbose option group declaration (and use it in rustc)
2012-10-17 13:05:04 -07:00
Kevin Cantu
32baf1c54c
Add a module to getopts to support verbose option definition
...
This is built on top of the existing functionality, but
adds a `groups` module which defines functions allowing
the user to specify whole short/long/description groups
at once and provides a usage message.
2012-10-17 12:10:06 -07:00
Tim Chevalier
7f12cc4e63
Merge pull request #3716 from Blei/fix-3656
...
rustc: fix size computation of structs for the FFI
2012-10-17 11:00:36 -07:00
Tim Chevalier
081a0434fb
Remove integer suffixes
2012-10-16 23:32:58 -07:00
Tim Chevalier
1679960889
Change a use of map::get to map::find
2012-10-16 23:32:57 -07:00
Patrick Walton
4dc67c5e6a
rustc: Implement intra-crate static methods on anonymous trait implementations.
2012-10-16 12:22:56 -07:00
Tim Chevalier
b38092e9a2
In ty::normalize_ty, don't replace self_regions with None
...
Instead, replace with re_static. This was causing ty::subst to
fail when called from trans::type_of::type_of.
Already discussed with nmatsakis and it's a small change, so
no review.
Closes #3447
2012-10-15 17:46:09 -07:00
Tim Chevalier
7d84505654
Error out in resolve if structs try to capture type parameters
...
Closes #3214
2012-10-15 16:27:53 -07:00
Patrick Walton
91ae5412d8
rustc: Merge module and type namespaces. r=brson
2012-10-15 15:35:36 -07:00
Patrick Walton
c886629d4f
rustc: Implement monomorphic default methods. r=nmatsakis
2012-10-15 14:14:05 -07:00
Niko Matsakis
2a1aa9fb53
Check whether loans conflict with old loans or with themselves.
...
Along the way, convert from dvec-of-dvec representation to track loans in scope
to just a single flattened list. It's more convenient.
Fixes #3765 . r+ pcwalton.
2012-10-15 13:37:50 -07:00
Tim Chevalier
0643466f85
Fix whitespace
2012-10-15 13:14:23 -07:00
Tim Chevalier
7237268b70
Allow enum discriminator exprs to refer to declared consts
...
Also some work towards #3521
Closes #2428
2012-10-15 12:28:29 -07:00
Tim Chevalier
9406f8101d
Avoid repeating 'try adding a move' hint
2012-10-12 22:15:13 -07:00
Tim Chevalier
f1e5b36ab2
Remove unneeded parens
2012-10-12 20:59:47 -07:00
Tim Chevalier
c6780fbb0c
Make trans ignore last use
2012-10-12 20:43:38 -07:00
Tim Chevalier
c4155f5ea3
Change the kind checker to ignore results of last-use
...
and require explicit moves.
Also provide more info in some error messages.
Also: check that non-copyable struct fields don't get copied.
Closes #3481
2012-10-12 20:43:38 -07:00
Tim Chevalier
9abc7f0a1c
(For legacy code:) In liveness, require that by-move arguments are rvalues
2012-10-12 20:43:38 -07:00
Tim Chevalier
d0ed13c4bd
Make moves explicit in rustc::middle
2012-10-12 20:43:37 -07:00
Niko Matsakis
98887cc7ee
remove ctor from ast (take 2) (no review: just dead code removal)
2012-10-12 19:46:37 -07:00
Niko Matsakis
cb55e246ba
Use the Nth impl when translating a static method call, instead
...
of the 0th. 0th is only correct when there are no bound tps
on the trait.
Fixes #3741 .
2012-10-12 17:46:43 -07:00
Graydon Hoare
57b4d10ff6
bump version to 0.5.
2012-10-12 16:41:32 -07:00
Kevin Cantu
1bede1f5e0
Replace several common macros of the form #m[...] with m!(...)
...
This commit replaces nearly all remaining uses of #fmt, #debug, #error,
and #info, and fixes some error messages...
2012-10-12 14:14:48 -07:00
Tim Chevalier
915897b3df
Remove obsolete comment
2012-10-11 16:46:06 -07:00
Tim Chevalier
7509a3d75b
Remove obsolete FIXME
2012-10-11 16:46:06 -07:00
Tim Chevalier
97c2255822
Use truncate in typeck::infer; gets rid of FIXME
2012-10-11 16:46:06 -07:00
Tim Chevalier
acaad9381d
Remove obsolete comment
2012-10-11 16:46:06 -07:00
Tim Chevalier
41752b02b9
Update FIXME numbers
2012-10-11 16:46:01 -07:00
Tim Chevalier
db679a738f
Remove obsolete FIXME
2012-10-11 16:46:00 -07:00
Tim Chevalier
6986acb340
Update FIXME numbers
2012-10-11 16:15:12 -07:00
Tim Chevalier
3764ec7025
Remove obsolete FIXME
2012-10-11 16:11:47 -07:00
Tim Chevalier
63dc83198a
Remove obsolete FIXME
2012-10-11 16:10:07 -07:00
Tim Chevalier
fb667cde59
Update FIXME number
2012-10-11 16:10:02 -07:00