| Age | Commit message (Collapse) | Author | Lines |
|
|
|
Issue #1736
|
|
|
|
There's no such thing anymore, we can simply call upcalls.cmp_type.
|
|
The free glue for opaque boxes will pick the actual tydesc out of the
box, and call its glue.
Issue #1736
|
|
Closes #1728
Comments out a section of debuginfo.rs. This code was already broken
(only being called when --xg was passed, and only working on trivial
programs).
|
|
It is now no longer needed to have a ty::ctxt to get at the contents
of a ty::t. The straight-forward approach of doing this, simply making
ty::t a box type, unfortunately killed our compiler performance (~15%
slower) through refcounting cost. Thus, this patch now represents
ty::t as an unsafe pointer, assuming that the ty::ctxt, which holds
these boxes alive, outlives any uses of the ty::t values. In the
current compiler this trivially holds, but it is does of course add a
new potential pitfall.
ty::get takes a ty::t and returns a boxed representation of the type.
I've changed calls to ty::struct(X) to do ty::get(X).struct. Type
structs are full of vectors, and copying them every time we wanted to
access them was a bit of a cost.
|
|
Closes #1761
|
|
This allows a 'Name:' to appear in front of an iface declaration's
name, which will cause 'Name' to refer to the self type (with the same
number of type parameters as the iface has) in the method signatures
of the iface. For example:
iface F: functor<A> {
fn fmap<B>(f: fn(A) -> B) -> F<B>;
}
Issue #1718
|
|
Conflicts:
src/libcore/vec.rs
src/libstd/getopts.rs
|
|
|
|
|
|
|
|
Added class support to the parser, prettyprinter, fold, and visit.
(See Issue 1726.)
This is WIP -- the test case is xfailed, and attempting to compile
it will error out in resolve.
|
|
as there may be more than one filemap with the same filename (in the
case of stdin for instance). This involved storing a pointer to the
filemap rather than the filename in location info such as
codemap::pos.
|
|
|
|
|
|
It had been messed up by the pretty-printer at some point, and was
partially out of date.
|
|
Adds a --monomorpize flag to rustc to turn it on. You probably don't
want to use it yet, since it's broken in a whole bunch of ways, but it
successfully monomorphizes simple generic functions called from within
the crate.
Issue #1736
|
|
The direct motivation for this was that the monomorphizer needs to be
able to generate sane symbols for random items. The typechecker can
probably also use this in the future to provide more useful error
messages.
|
|
It's been sitting unused long enough to have bitrotted completely.
|
|
Closes #1733
|
|
str::unsafe::safe_slice -> str::unsafe::slice_bytes_safe_range
|
|
|
|
this will be used to generate a new snapshot.
|
|
snapshot is prepared.
|
|
|
|
Issue #1673
|
|
Code is still somewhat kludgy because we don't have 32-bit enums.
Issue #1673
|
|
Now that core exports "option" as a synonym for option::t, search-and-
replace option::t with option.
The only place that still refers to option::t are the modules in libcore
that use option, because fixing this requires a new snapshot
(forthcoming).
|
|
Since item_consts can't refer to or modify local variables, they
don't participate in typestate and thus get empty pre and
postconditions by default.
Closes #1660
|
|
middle::check_alt does the work. Lots of changes to add default cases
into alts that were previously inexhaustive.
|
|
|
|
This allows us to express option::map with noncopyable type
parameters, which makes sense, since the type params aren't being
copied (none doesn't contain any).
|
|
`expr_ternary`, `ternary_to_if`, and all parses & lexer definitions have
been removed.
|
|
All the files below had at least one instance of the ternary operator
present in the source. All have been changed to the equivalent
if/then/else expression.
|
|
This simplifies the typechecker a bit (no more ty_param_substs_opt_and_ty)
and is needed for another experiment I'm playing with. I hope it also
makes compilation faster (the bots will tell).
|
|
|
|
|
|
I.e. a set of curly braces, not everything that creates a block
context in the trans pass.
Issue #1694
|
|
|
|
Closes #1700
|
|
Almost all of the vec functions that predicates don't have a
corresponding function that takes a single element, so this
commit renames the common fn usecase to be the default.
|
|
|
|
time while #1694 is unfixed, and fix stack-exhaustion bug in block parent generation.
|
|
|
|
Conflicts:
src/comp/driver/driver.rs
src/comp/middle/trans/base.rs
src/comp/syntax/parse/lexer.rs
|
|
It wouldn't detect cycles that went through several type vars before.
Closes #1464
|
|
This makes it possible to de-initialize values anywhere in
memory, which is needed, for example, for a fast imlementation
of vec::pop.
|
|
Closes #742
|