Marvin Löbel
54f4dcd76a
Prepared std::sys
for removal, and made begin_unwind
simpler
...
- `begin_unwind` is now generic over any `T: Any + Send`.
- Every value you fail with gets boxed as an `~Any`.
- Because of implementation details, `&'static str` and `~str` are still
handled specially behind the scenes.
- Changed the big macro source string in libsyntax to a raw string
literal, and enabled doc comments there.
2013-10-30 21:19:18 +01:00
Marvin Löbel
fa8e71a825
Allow fail messages to be caught, and introduce the Any trait
...
Some code cleanup, sorting of import blocks
Removed std::unstable::UnsafeArc's use of Either
Added run-fail tests for the new FailWithCause impls
Changed future_result and try to return Result<(), ~Any>.
- Internally, there is an enum of possible fail messages passend around.
- In case of linked failure or a string message, the ~Any gets
lazyly allocated in future_results recv method.
- For that, future result now returns a wrapper around a Port.
- Moved and renamed task::TaskResult into rt::task::UnwindResult
and made it an internal enum.
- Introduced a replacement typedef `type TaskResult = Result<(), ~Any>`.
2013-10-28 08:50:32 +01:00
bors
950add4e49
auto merge of #10072 : brson/rust/modelines, r=thestinger
...
These are relics that serve no purpose.
2013-10-26 02:16:08 -07:00
Brian Anderson
9a773da681
Remove ancient emacs mode lines from test cases
...
These are relics that serve no purpose.
2013-10-25 17:41:54 -07:00
bors
dcdcd309fb
auto merge of #10067 : sanxiyn/rust/addr-of-bot, r=thestinger
...
Fix #5500 .
2013-10-25 12:56:20 -07:00
Seo Sanghyeon
f04886b6bf
Allow taking address of bottom
2013-10-25 19:15:29 +09:00
Alex Crichton
61ed2cfb55
Remove even more of std::io
...
Big fish fried here:
extra::json
most of the compiler
extra::io_util removed
extra::fileinput removed
Fish left to fry
extra::ebml
2013-10-24 14:21:57 -07:00
Daniel Micay
142672dca4
register snapshots
2013-10-23 18:06:12 -04:00
Alex Crichton
daf5f5a4d1
Drop the '2' suffix from logging macros
...
Who doesn't like a massive renaming?
2013-10-22 08:09:56 -07:00
Huon Wilson
ab045fa797
testsuite: test for fixed issue. Closes #7580 .
...
Fixed by the privacy changes that allowed the `mod std {}` at the top
level of `std` to be non-`pub`.
2013-10-20 20:19:29 +11:00
Brian Anderson
34d376f3cf
std: Move size/align functions to std::mem. #2240
2013-10-17 17:31:35 -07:00
Daniel Micay
aa93381e14
fix overflow on bounds checks
...
Closes #9020
2013-10-15 16:23:28 -04:00
Daniel Micay
420b4260b4
fix bounds checking failure message
...
casting the `uint` to an `int` can result in printing high values as
negative intege
2013-10-15 16:23:26 -04:00
Marvin Löbel
517298de48
Implemented IntoSendStr
on SendStr
to allow naming a
...
task with a `SendStr` directly
2013-10-05 21:28:04 +02:00
Marvin Löbel
49ac6baa72
Make a task name use a SendStr
, allowing for either
...
static or owned strings
2013-10-05 21:01:58 +02:00
Daniel Micay
c9d4ad07c4
remove the float
type
...
It is simply defined as `f64` across every platform right now.
A use case hasn't been presented for a `float` type defined as the
highest precision floating point type implemented in hardware on the
platform. Performance-wise, using the smallest precision correct for the
use case greatly saves on cache space and allows for fitting more
numbers into SSE/AVX registers.
If there was a use case, this could be implemented as simply a type
alias or a struct thanks to `#[cfg(...)]`.
Closes #6592
The mailing list thread, for reference:
https://mail.mozilla.org/pipermail/rust-dev/2013-July/004632.html
2013-10-01 14:54:10 -04:00
Alex Crichton
02054ac8a1
rfail: Remove usage of fmt!
2013-09-30 23:21:20 -07:00
bors
10e7f12daf
auto merge of #9550 : alexcrichton/rust/remove-printf, r=thestinger
...
The 0.8 release was cut, down with printf!
2013-09-27 08:21:23 -07:00
Alex Crichton
409182de6d
Update the compiler to not use printf/printfln
2013-09-26 17:05:59 -07:00
Alex Crichton
eb2b25dd6d
Refactor the logging system for fewer allocations
...
This lifts various restrictions on the runtime, for example the character limit
when logging a message. Right now the old debug!-style macros still involve
allocating (because they use fmt! syntax), but the new debug2! macros don't
involve allocating at all (unless the formatter for a type requires allocation.
2013-09-25 16:30:05 -07:00
Patrick Walton
90d3da9711
test: Fix rustdoc and tests.
2013-09-23 18:23:22 -07:00
Daniel Micay
4e161a4d40
switch Drop to &mut self
2013-09-16 22:19:23 -04:00
Daniel Micay
298f06f267
make ! support the equality/ordering operators
...
An expression such as `bottom == not_bottom` or `not_bottom == bottom`
already compiled, but this fixes the case where both sides are `bottom`.
2013-09-13 17:31:59 -04:00
Huon Wilson
4fea236a85
extra: error message should reflact that RUST_TEST_TASKS should be strictly positive (zero is illegal).
2013-08-29 22:58:27 +10:00
Huon Wilson
3f791acf4d
Make the unit-test framework check RUST_TEST_TASKS over RUST_THREADS.
...
Fixes #7335 .
2013-08-29 11:17:09 +10:00
Vadim Chugunov
39fc0883fd
Enabled tests.
2013-08-22 00:12:44 -07:00
bors
b26e11db86
auto merge of #8560 : kballard/rust/reserve-yield, r=pcwalton
...
Rename task::yield() to task::deschedule().
Fixes #8494 .
2013-08-18 15:02:04 -07:00
Erick Tryzelaar
ad5c676853
Fix warnings it tests
2013-08-17 08:42:35 -07:00
Kevin Ballard
418e1ebae6
Reserve 'yield' keyword
...
Rename task::yield() to task::deschedule().
Fixes #8494 .
2013-08-16 13:26:50 -07:00
Daniel Micay
3cec67bbf2
rm obsolete test
2013-08-15 21:12:54 -04:00
bors
e86d414f22
auto merge of #8497 : nikomatsakis/rust/improvements-to-object-coercion, r=pcwalton
...
While looking over the code for object coercion, I realized that it wasn't quite handling freezing and reborrowing correctly. Tweak the code, adding tests for the relevant cases.
r? @pcwalton
2013-08-13 21:29:20 -07:00
Graydon Hoare
26fd428fae
Merge pull request #8432 from chris-morgan/remove-assert-eq-macro-fail-binary
...
Remove in-tree test binary.
2013-08-13 14:51:36 -07:00
Niko Matsakis
afb20775d1
Fix freezing of @mut Objects when passing as argument
2013-08-13 15:52:04 -04:00
Niko Matsakis
b402e343e4
tests: Add new tests for borrowck/objects and update some existing tests
2013-08-11 14:01:23 -04:00
Chris Morgan
1ceee6a843
Remove in-tree test binary.
...
I presume this was accidentally committed.
2013-08-10 16:14:39 +10:00
bors
8f65dbfcfa
auto merge of #8385 : cmr/rust/big-rollup, r=alexcrichton
...
This is a fairly large rollup, but I've tested everything locally, and none of
it should be platform-specific.
r=alexcrichton (bdfdbdd)
r=brson (d803c18)
r=alexcrichton (a5041d0)
r=bstrie (317412a)
r=alexcrichton (135c85e)
r=thestinger (8805baa)
r=pcwalton (0661178)
r=cmr (9397fe0)
r=cmr (caa4135)
r=cmr (6a21d93)
r=cmr (4dc3379)
r=cmr (0aa5154)
r=cmr (18be261)
r=thestinger (f10be03)
2013-08-08 14:32:02 -07:00
Kevin Ballard
8964fcc5ac
Implement DoubleEndedIterator on Range
...
Range is now invertable as long as its element type conforms to Integer.
Remove int::range_rev() et al in favor of range().invert().
2013-08-07 22:41:09 -04:00
Brian Anderson
ce95b01014
Disable linked failure tests
...
The implementation currently contains a race that leads to segfaults.
2013-08-07 16:32:20 -07:00
Marvin Löbel
0ac7a219f0
Updated std::Option, std::Either and std::Result
...
- Made naming schemes consistent between Option, Result and Either
- Changed Options Add implementation to work like the maybe monad (return None if any of the inputs is None)
- Removed duplicate Option::get and renamed all related functions to use the term `unwrap` instead
2013-08-05 22:42:21 +02:00
Daniel Micay
1008945528
remove obsolete foreach
keyword
...
this has been replaced by `for`
2013-08-03 22:48:02 -04:00
toddaaro
eab749a5f3
modified logging function to truncate output and adjusted error output formatting tests to be compatible with both the new and old runtimes
2013-08-03 03:09:04 -04:00
Daniel Micay
234acad404
replace range
with an external iterator
2013-08-02 00:51:14 -04:00
bors
d346f1a40e
auto merge of #8172 : brson/rust/nomorestack, r=pcwalton
...
The new scheduler does not yet implement split stacks
2013-08-01 16:19:37 -07:00
blake2-ppc
78cde5b9fb
std: Change Times
trait to use do
instead of for
...
Change the former repetition::
for 5.times { }
to::
do 5.times { }
.times() cannot be broken with `break` or `return` anymore; for those
cases, use a numerical range loop instead.
2013-08-01 16:54:22 +02:00
Brian Anderson
1d256ba6e8
test: Disable morestack tests
...
The new scheduler does not yet implement split stacks
2013-07-31 18:11:19 -07:00
bors
20454da2db
auto merge of #8069 : erickt/rust/maikklein, r=erickt
...
Good evening,
This is a superset of @MaikKlein's #7969 commit, that I've fixed up to compile. I had a couple commits I wanted to do on top of @MaikKlein's work that I didn't want to bitrot.
2013-07-28 00:19:21 -07:00
Erick Tryzelaar
ea106f72f7
core: correct the casing of result::{Ok,Err} in the docs
2013-07-27 23:42:53 -07:00
Erick Tryzelaar
2a68c719f4
to_either + fixes
2013-07-27 23:41:09 -07:00
Steven Stewart-Gallus
d0b7515aed
Change concurrency primitives to standard naming conventions
...
To be more specific:
`UPPERCASETYPE` was changed to `UppercaseType`
`type_new` was changed to `Type::new`
`type_function(value)` was changed to `value.method()`
2013-07-27 22:06:29 -07:00
Birunthan Mohanathas
206ae5752e
Change 'print(fmt!(...))' to printf!/printfln! in src/test/
2013-07-24 09:45:20 -04:00
Huon Wilson
de2b5c50cd
test/run-fail: Un-xfail a test, make some other xfailed ones compile (they still don't work).
2013-07-23 18:55:15 +10:00
bors
e336cbf8f9
auto merge of #7923 : alexcrichton/rust/add-tests, r=graydon
...
Closes #5275 , #4547
2013-07-21 13:07:45 -07:00
Patrick Walton
06594ed96b
librustc: Remove pub extern
and priv extern
from the language.
...
Place `pub` or `priv` on individual items instead.
2013-07-20 17:39:38 -07:00
Alex Crichton
0bba8f4b74
Add tests for issues which can be closed
...
Closes #5275 , $4547
2013-07-19 19:01:46 -07:00
Patrick Walton
99b33f7219
librustc: Remove all uses of "copy".
2013-07-17 14:57:51 -07:00
Huon Wilson
e4f7561bcd
Clean-up tests after debug!/std-macros change.
...
The entire testsuite is converted to using info! rather than debug!
because some depend on the code within the debug! being trans'd.
2013-07-17 03:10:13 +10:00
Corey Richardson
26f0a55f76
fix test
2013-07-10 13:14:31 -04:00
Huon Wilson
cdea73cf5b
Convert vec::{as_imm_buf, as_mut_buf} to methods.
2013-07-04 00:46:50 +10:00
Patrick Walton
a1531ed946
librustc: Remove the broken overloaded assign-ops from the language.
...
They evaluated the receiver twice. They should be added back with
`AddAssign`, `SubAssign`, etc., traits.
2013-06-28 10:44:16 -04:00
Patrick Walton
1c0aa78481
librustc: Change "Owned" to "Send" everywhere
2013-06-28 10:44:15 -04:00
Luqman Aden
ca2966c6d0
Change finalize -> drop.
2013-06-25 21:14:39 -04:00
Daniel Micay
e2e39234cc
remove old_iter
...
the `test/run-pass/class-trait-bounded-param.rs` test was xfailed and
written in an ancient dialect of Rust so I've just removed it
this also removes `to_vec` from DList because it's provided by
`std::iter::to_vec`
an Iterator implementation is added for OptVec but some transitional
internal iterator methods are still left
2013-06-24 01:35:11 -04:00
Huon Wilson
c32fb53cf9
std: remove str::{len, slice, is_empty} in favour of methods.
2013-06-10 23:02:54 +10:00
Patrick Walton
8114d0e950
librustc: Disallow multiple patterns from appearing in a "let" declaration.
...
You can still initialize multiple variables at once with "let (x, y) = (1, 2)".
2013-06-04 21:45:42 -07:00
Patrick Walton
206ab89629
librustc: Stop reexporting the standard modules from prelude.
2013-05-29 19:04:53 -07:00
Lindsey Kuper
32c6199161
Change alt
to match
in filenames.
2013-05-27 17:28:39 -04:00
Patrick Walton
1be40be613
test: Update tests to use the new syntax.
2013-05-22 21:57:10 -07:00
bors
9f671698e6
auto merge of #6106 : thestinger/rust/iter, r=bstrie
...
I don't have a strong opinion on the function vs. method, but there's no point in having both. I'd like to make a `repeat` adaptor like Python/Haskell for turning a value into an infinite stream of the value, so this has to at least be renamed.
2013-05-19 08:13:30 -07:00
Corey Richardson
cc57ca012a
Use assert_eq! rather than assert! where possible
2013-05-19 08:16:02 -04:00
Daniel Micay
d953a5ce43
replace old_iter::repeat with the Times trait
2013-05-18 04:57:21 -04:00
Marvin Löbel
04de8f852c
Fix cosmetics for fail!() calls
2013-05-14 16:36:24 +02:00
Björn Steinbrink
bdc182cc41
Use static string with fail!() and remove fail!(fmt!())
...
fail!() used to require owned strings but can handle static strings
now. Also, it can pass its arguments to fmt!() on its own, no need for
the caller to call fmt!() itself.
2013-05-14 16:36:23 +02:00
Niko Matsakis
9482ed729e
test: Add two tests for issue #6272 .
2013-05-09 17:25:17 -04:00
bors
ca95e7f94e
auto merge of #6345 : seanmoon/rust/fix-typos, r=sanxiyn
...
Hi there,
Really enjoying Rust. Noticed a few typos so I searched around for a few more--here's some fixes.
Ran `make check` and got `summary of 24 test runs: 4868 passed; 0 failed; 330 ignored`.
Thanks!
Sean
2013-05-09 03:51:32 -07:00
Patrick Walton
9d011ebf67
test: Fix tests.
2013-05-08 17:04:02 -07:00
Sean Moon
bd4ee7c7d2
Fix typos
2013-05-09 02:34:47 +09:00
Niko Matsakis
2e4790ca06
Merge remote-tracking branch 'mozilla/incoming' into issue-5910-dyna-freeze
2013-05-06 16:10:31 -04:00
Brendan Zabarauskas
0e2242f6d6
Add assert_approx_eq! macro
2013-05-06 21:51:48 +10:00
Niko Matsakis
7b36e34c89
Fix two more write guard failures
2013-05-05 21:05:37 -04:00
Niko Matsakis
4300d4d2fa
Merge remote-tracking branch 'mozilla/incoming' into issue-5910-dyna-freeze
...
Conflicts:
src/libcore/core.rc
src/libcore/hashmap.rs
src/libcore/num/f32.rs
src/libcore/num/f64.rs
src/libcore/num/float.rs
src/libcore/num/int-template.rs
src/libcore/num/num.rs
src/libcore/num/strconv.rs
src/libcore/num/uint-template.rs
src/libcore/ops.rs
src/libcore/os.rs
src/libcore/prelude.rs
src/libcore/rt/mod.rs
src/libcore/unstable/lang.rs
src/librustc/driver/session.rs
src/librustc/middle/astencode.rs
src/librustc/middle/borrowck/check_loans.rs
src/librustc/middle/borrowck/gather_loans.rs
src/librustc/middle/borrowck/loan.rs
src/librustc/middle/borrowck/preserve.rs
src/librustc/middle/liveness.rs
src/librustc/middle/mem_categorization.rs
src/librustc/middle/region.rs
src/librustc/middle/trans/base.rs
src/librustc/middle/trans/inline.rs
src/librustc/middle/trans/reachable.rs
src/librustc/middle/typeck/check/_match.rs
src/librustc/middle/typeck/check/regionck.rs
src/librustc/util/ppaux.rs
src/libstd/arena.rs
src/libstd/ebml.rs
src/libstd/json.rs
src/libstd/serialize.rs
src/libstd/std.rc
src/libsyntax/ast_map.rs
src/libsyntax/parse/parser.rs
src/test/compile-fail/borrowck-uniq-via-box.rs
src/test/compile-fail/regions-infer-borrow-scope-within-loop.rs
src/test/run-pass/borrowck-nested-calls.rs
2013-05-05 15:11:04 -04:00
Daniel Micay
86efd97a10
add gitattributes and fix whitespace issues
2013-05-03 20:01:42 -04:00
Niko Matsakis
be08c3e514
rustc: add rooting, write-guards to slices etc
2013-05-03 16:27:16 -04:00
Brendan Zabarauskas
ee26c7c433
Revert rename of Div to Quot
2013-05-01 15:40:05 +10:00
Niko Matsakis
f236b850c0
remove some unused mut decls
2013-04-30 16:35:01 -04:00
Patrick Walton
c6a9e28842
librustc: Rename reinterpret_cast
to transmute_copy
and remove the intrinsic
2013-04-29 14:30:53 -07:00
Daniel Micay
46f91a0fa9
make way for a new iter module
2013-04-28 22:31:39 -04:00
bors
88dd53a754
auto merge of #6081 : brson/rust/out-of-stack, r=thestinger
...
People hit the recursion depth limit too often, it's not possible
to unwind reliably from out-of-stack.
Issues #3555 , #3695
2013-04-27 16:24:34 -07:00
Brian Anderson
149047e55d
rt: Set the stack depth limit to 1GB. Abort on error.
...
People hit the recursion depth limit too often, it's not possible
to unwind reliably from out-of-stack.
Issues #3555 , #3695
2013-04-26 15:39:54 -07:00
Marvin Löbel
928a07e9cb
Added test cases for all fail message formats
2013-04-26 10:23:12 +02:00
Marvin Löbel
e1be9ae224
Made fail! and assert! accept both &'static str and ~str, as well as a fmt! like format list.
...
Unwinding through macros now happens as a call to the trait function `FailWithCause::fail_with()`, which consumes self, allowing to use a more generic failure object in the future.
2013-04-25 17:32:25 +02:00
Brendan Zabarauskas
ab8068c9f2
Improve divide-by-zero error messages
2013-04-24 14:20:00 +10:00
Brendan Zabarauskas
01eb5e8ad3
Rename Div operator trait to Quot and Modulo operator trait to Rem
2013-04-22 01:58:53 +10:00
Daniel Micay
cc148b58ff
rename Linear{Map,Set} => Hash{Map,Set}
2013-04-03 10:30:36 -04:00
Daniel Micay
44029a5bbc
hashmap: rm linear namespace
2013-04-03 10:30:18 -04:00
Patrick Walton
1e91595520
librustc: Remove fail_unless!
2013-03-29 16:39:08 -07:00
Daniel Micay
11ca2efce1
turn std::oldmap into a wrapper around LinearMap
2013-03-23 02:16:14 -04:00
Patrick Walton
3eda11a4f7
test: Remove pure
from the test suite
2013-03-22 12:57:28 -07:00
Andrew Paseltiner
ec960963c1
test: replace uses of old deriving attribute with new one
2013-03-22 06:30:53 -04:00
bors
d52408d46a
auto merge of #5480 : pcwalton/rust/at-const, r=pcwalton
...
r? @catamorphism
2013-03-21 20:39:51 -07:00
Patrick Walton
d4fee24c7c
librustc: Forbid destructors from being attached to any structs that might contain non-Owned fields. r=nmatsakis
2013-03-21 17:31:34 -07:00
John Clements
ab8e46b066
add assert_eq! macro
...
the assert_eq! macro compares its arguments and fails if they're not
equal. It's more informative than fail_unless!, because it explicitly
writes the given and expected arguments on failure.
2013-03-20 13:27:45 -07:00
Alex Crichton
14df844744
Allow custom messages on assert statements
2013-03-19 14:07:00 -04:00
Patrick Walton
8fa66e8e07
librustc: Remove implicit self from the language, except for old-style drop blocks.
2013-03-13 20:07:10 -07:00
Niko Matsakis
852619d5d7
Remove ++
mode from the compiler (it is parsed as +
mode)
...
and obsolete `-` mode altogether (it *was* parsed as `+` mode).
2013-03-13 17:00:09 -04:00
Brian Anderson
9c7e16e48d
Remove the log keyword (by renaming it to __log)
...
We can't quite remove logging from the language, but this hides the
keyword.
2013-03-11 23:19:42 -07:00
Brian Anderson
82f190355b
Remove uses of log
2013-03-11 23:19:42 -07:00
Patrick Walton
d18f785457
librustc: Replace all uses of fn()
with &fn()
. rs=defun
2013-03-11 09:35:58 -07:00
Patrick Walton
d661711cc2
test: Fix tests.
2013-03-07 22:37:58 -08:00
Patrick Walton
d7e74b5e91
librustc: Convert all uses of assert
over to fail_unless!
2013-03-07 22:37:57 -08:00
Patrick Walton
6b5d1afeec
librustc: Remove "extern mod { ... }" from librustc, librustdoc, and tests. rs=deexterning
2013-03-07 22:32:52 -08:00
Patrick Walton
30bb09c0e7
test: Remove fn@
, fn~
, and fn&
from the test suite. rs=defun
2013-03-02 18:47:47 -08:00
Patrick Walton
a3f728238b
librustc: Forbid chained imports and fix the logic for one-level renaming imports
2013-03-02 16:49:30 -08:00
Niko Matsakis
4ecb672d7f
Remove legacy object creation mode, and convert remaining uses of it
2013-02-28 20:28:04 -05:00
Ben Striegel
43d43adf6b
Turn old drop
blocks into Drop
traits
2013-02-27 19:14:19 -05:00
Patrick Walton
f9f942bb14
test: Fix comments in pretty-printed test. rs=burningtree
2013-02-23 23:33:50 -08:00
Brian Anderson
dab6a85230
core: Extract comm from pipes. #4742
2013-02-21 17:36:54 -08:00
Patrick Walton
bf2a225c0b
librustc: Separate most trait bounds with '+'. rs=plussing
2013-02-20 21:14:20 -08:00
Luqman Aden
178882c98f
tests/tutorials: Get rid of move
.
2013-02-15 02:49:55 -08:00
Luqman Aden
cc89029942
libcore: Remove ptr::mut_addr_of since &mut is coerced to *mut
2013-02-14 18:36:10 -08:00
Patrick Walton
9143688197
librustc: Replace impl Type : Trait
with impl Trait for Type
. rs=implflipping
2013-02-14 14:44:12 -08:00
Nick Desaulniers
4445b38df2
Remove die!, raplace invocations with fail! Issue #4524 pt 3
2013-02-13 17:01:32 -08:00
Luqman Aden
70185fdcc2
rt: remove last_os_error and adjust tests.
2013-02-11 23:49:49 -05:00
Daniel Micay
319eeb1c79
rename map -> oldmap and mark it as deprecated
...
LinearMap is quite a bit faster, and is fully owned/sendable without
requiring copies. The older std::map also doesn't use explicit self and
relies on mutable fields.
2013-02-03 15:55:10 -05:00
Nick Desaulniers
7868b6bf55
Remove fail keyword from lexer & parser and clean up remaining calls to
...
fail
Fix merge conflicts - Issue 4524
2013-02-01 00:15:42 -08:00
Nick Desaulniers
6fb4239bb3
Replace most invocations of fail keyword with die! macro
2013-01-31 22:25:12 -08:00
Nick Desaulniers
aee7929469
Replace most invocations of fail keyword with die! macro
2013-01-31 20:12:49 -08:00
Niko Matsakis
0682ad0eb9
Finalize moves-based-on-type implementation.
...
Changes:
- Refactor move mode computation
- Removes move mode arguments, unary move, capture clauses
(though they still parse for backwards compatibility)
- Simplify how moves are handled in trans
- Fix a number of illegal copies that cropped up
- Workaround for bug involving def-ids in params
(see details below)
Future work (I'll open bugs for these...):
- Improve error messages for moves that are due
to bindings
- Add support for moving owned content like a.b.c
to borrow check, test in trans (but I think it'll
"just work")
- Proper fix for def-ids in params
Def ids in params:
Move captures into a map instead of recomputing.
This is a workaround for a larger bug having to do with the def-ids associated
with ty_params, which are not always properly preserved when inlining. I am
not sure of my preferred fix for the larger bug yet. This current fix removes
the only code in trans that I know of which relies on ty_param def-ids, but
feels fragile.
2013-01-31 12:09:00 -08:00
Patrick Walton
2a65842c3a
test: De-export aux, bench, compile-fail, and run-fail. rs=deexporting
2013-01-30 15:08:45 -08:00
Brian Anderson
02e907b648
Remove oldcomm from the test suite
2013-01-30 00:48:10 -08:00
Patrick Walton
6ce74460e6
librustc: Disallow trait bounds in types, enumerations, and structure definitions. r=tjc
2013-01-29 10:42:58 -08:00
Tim Chevalier
bb183b93ea
testsuite: Eliminate structural records from run-fail tests
2013-01-26 11:38:00 -08:00
Patrick Walton
ad25e208ee
librustc: Allow &mut
to be loaned; allow self
to be loaned; make &mut
loanable to &
. r=nmatsakis
2013-01-24 13:52:22 -08:00
Patrick Walton
163b97b7bb
librustc: Make C functions unsafe
2013-01-24 13:52:21 -08:00
Patrick Walton
154488df19
libsyntax: Implement assert
as a macro (called fail_unless!
on a transitionary basis to avoid conflicting with the keyword right now). r=brson
2013-01-23 14:46:24 -08:00
Patrick Walton
54b2cad8b3
libsyntax: Remove fn() unsafe { ... }
. r=graydon
2013-01-23 14:41:08 -08:00
Tim Chevalier
885f0a2eab
testsuite: Un-xfail test for #3029 and move to run-fail
2013-01-20 20:35:24 -08:00
Patrick Walton
f405e41d7a
librustc: Implement write guards for borrowing @mut
to &
or &mut
. r=nmatsakis
2013-01-17 11:50:20 -08:00
Graydon Hoare
84825ee310
librustc: Make the default sigil for block lambdas &
instead of @
.
2013-01-15 17:57:45 -08:00
Niko Matsakis
737e115646
mode: reset mode on entry to fn body.
...
This is an interim fix to address the "Beware!" unsoundness. I have a
more comprehensive rewrite of mode.rs in the pipeline.
r=pcwalton
2013-01-10 13:17:25 -08:00
Brian Anderson
8979695496
Fix broken tests
2012-12-14 15:10:45 -08:00
Brian Anderson
e6d1b02359
Rename core::comm to core::oldcomm
2012-12-14 14:59:32 -08:00
Brian Anderson
ed4fac01b5
Rename Send trait to Owned
2012-12-13 15:52:50 -08:00
Brian Anderson
3fcdb7d6a7
Adjust the die macro to only accept ~str and to work in statement position
2012-12-10 18:16:22 -08:00
Graydon Hoare
d1affff623
Reliciense makefiles and testsuite. Yup.
2012-12-10 17:32:58 -08:00
Patrick Walton
b27150ef82
test: Fix some run-fail bustage. rs=bustage
2012-12-06 10:26:11 -08:00
Patrick Walton
9e1c9be16f
librustc: Make the Drop trait use explicit self
2012-11-29 11:06:15 -08:00
Brian Anderson
8b309e54c7
re-xfail two tests
2012-11-16 11:19:45 -08:00
Tim Chevalier
624fbbd3d1
Update and un-xfail tests
2012-11-15 19:57:46 -08:00
Ben Striegel
f4a5a76aa4
Convert the test suite to use the Drop trait
2012-11-14 19:26:37 -08:00
Brian Anderson
a90020fe8d
xfail issue-2061
2012-11-01 17:13:59 -07:00