Graydon Hoare
6e3a77c3a3
Merge remote branch 'tohava/master'
...
Conflicts:
src/boot/fe/ast.ml
2010-08-23 18:19:42 -07:00
Or Brostovski
0830b5bf24
Modified parser to handle alt type andadded a few tests
...
ast.ml - modified arm types for easier polymorphism
- fixed a bug in fmt_type_arm
dead.ml - modified arm types for easier polymorphism
common.ml - added 'either'
- added some useful auxiliary functions
item.ml - modified arm code to be more polymorphic and handle both alt-tag and alt-type, also fixed the problematic case in bad-alt.rs
Makefile - added XFAIL for new alt-type test
bad-alt.rs - added test for invalid alt syntax
alt-type-simple.rs - added simple test for alt type
2010-08-21 02:41:43 +03:00
Roy Frostig
2da4fecacd
Test the buffered reader and writer in _io.
2010-08-20 12:57:38 -07:00
Graydon Hoare
ddd8feea31
Support single-element append on vec, str. Closes #44 .
2010-08-20 09:58:22 -07:00
Graydon Hoare
b34cb1b631
Fix a bunch of typestate bugs in handling if and while statement wirings.
2010-08-19 18:42:32 -07:00
Michael Bebenita
14f5b5750d
Un-xfailed working tests.
2010-08-16 15:05:57 -07:00
Roy Frostig
abe307cf45
Uncomment recently-no-longer-failing std.deque tests. Add a few arbitrary-access checks.
2010-08-13 11:55:25 -07:00
Roy Frostig
73ee16b1a4
A little tidy-up that should have gone in with 4e376852e7
.
2010-08-12 19:20:29 -07:00
Roy Frostig
4e376852e7
Fix max_sz bug that ended up causing us to index incorrectly into a vec of tag types. Add a testcase.
2010-08-12 16:21:08 -07:00
Michael Bebenita
988695a96c
Added support for task sleeping in the scheduler.
2010-08-11 21:24:04 -07:00
Michael Bebenita
74e12fcef6
Ignore upcall_flush for channels that are disassociated from ports. This makes task-comm-10 break a little less hard, but it still leaks because messages pending in the channel are never freed.
2010-08-11 16:08:45 -07:00
Michael Bebenita
8ac15c6844
Added test cases.
2010-08-11 16:08:45 -07:00
Roy Frostig
f307688bf4
Add native vec[u8] to str converter. Put in workaround for leak in str to vec[u8] converter. Add testcase exercising both. Drive-by fix a potential array-out-of-bounds write on rust_str buffers.
2010-08-11 16:06:45 -07:00
Graydon Hoare
9f6dec9e13
Always bounce mul/div/mod ops. Closes #131 harder.
2010-08-10 16:03:58 -07:00
Michael Bebenita
d647c163fd
Updated/added test cases.
2010-08-09 06:53:37 -07:00
Jeffrey Yasskin
3f6e8ffe64
Implement _str.len() to return the number of bytes, rename it to byte_len(),
...
and add a test.
2010-08-06 17:29:21 -07:00
Jeffrey Yasskin
581a95a804
Add an int->str conversion function.
...
The test currently fails because string equality isn't implemented.
2010-08-06 17:25:27 -07:00
Jeffrey Yasskin
987589e946
Change the destructor-ordering test to use channels instead of a shared mutable object.
...
This test used to take advantage of a hole in the type system that allows
objects with destructors to refer to stateful objects.
2010-08-06 17:17:04 -07:00
Graydon Hoare
29987b56e1
Move 'as' precedence up to just above relational; support indexing str and vec by all integral types. Closes #94 .
2010-08-05 10:04:11 -07:00
Roy Frostig
718c0b5963
Add to std._io some formatter/type-specific-writer mechanism. Make a few type-specific buffered writers as wrappers of buf_writer.
2010-08-04 23:09:33 -07:00
Graydon Hoare
815424c2ec
Fix pexp parser to do left-associativity, not right. Closes #130 .
2010-08-04 13:44:22 -07:00
Graydon Hoare
7595aca5e3
Kill the preallocator, install a sane replacement. Closes #131 . And probably a lot of others.
2010-08-04 00:27:36 -07:00
Roy Frostig
6277b462e9
More stdlib hashmap work. Add a simple test and XFAIL it due to a valgrind-spotted UMR.
2010-08-03 18:43:57 -07:00
Roy Frostig
5b2451c231
Address _vec.map allocation FIXME. Add test.
2010-08-03 18:18:19 -07:00
Graydon Hoare
a1ecdb103d
Fix some naughtiness of handling newlines in bracequotes and multi-line comments. Closes #142 .
2010-08-03 16:28:50 -07:00
Graydon Hoare
1fc4e9fcc6
Add tests and fix pexp bug. Closes #141 .
2010-08-03 12:20:29 -07:00
Michael Bebenita
74a79fff3a
Add a bunch of comm tests.
2010-07-28 20:30:30 -07:00
Roy Frostig
dfcf21ca82
Another deque test commented out.
2010-07-28 18:14:33 -07:00
Roy Frostig
c489af8e1a
Test the deque some more.
2010-07-28 17:31:41 -07:00
Roy Frostig
237b9d4a64
Test the deque more and fix uncovered off-by-one bug.
2010-07-28 16:34:22 -07:00
Roy Frostig
f282c5ccc0
Get slots in trans_tag using Semant tables. Closes #133 .
2010-07-28 15:04:58 -07:00
Roy Frostig
596d19e2ea
Test the deque a bit. Give it a get-by-index method. Fix two uncovered state-calculation bugs --- one decently, the other with an ugly hack. Bug on the latter coming right up.
2010-07-28 14:00:44 -07:00
Graydon Hoare
8030757624
Switch machine-type lexemes to use suffixes. Remove support for foo(bar) as a cast notation. Closes #129 .
2010-07-27 19:21:51 -07:00
Graydon Hoare
4d31cf1dc5
Distill semantics of use-def maps to fewer and more-obvious words.
...
- Remove redundant uses of 'resolve' and 'referent' in semant.
- Use defn, defn_id, lval, lval_base more consistently.
- Make associated query functions more consistent.
- Closes #127 .
2010-07-27 11:19:43 -07:00
Roy Frostig
1a61fb8eb7
Adjust testcase to cover issue #91 , which was actually fixed back in commit f02f9cbf29
. Closes #91 .
2010-07-26 15:52:59 -07:00
Patrick Walton
4b97b4e79d
Move the test suite to the "as" form for casts. XFAIL a few tests for LLVM.
2010-07-26 15:22:21 -07:00
Roy Frostig
5b6e714d05
Expose an RNG (the one used by our runtime) to Rust via std.
2010-07-25 21:45:09 -07:00
Graydon Hoare
44e2dc2789
Improve mutability checking. Closes #118 .
2010-07-23 15:29:17 -07:00
Graydon Hoare
8bd8413906
Add test for writing-through-uninit bug (reported on IRC by jrmuizel), plus fix in typestate system.
2010-07-23 13:52:46 -07:00
Graydon Hoare
fe82978980
Modify testcase to match new syntax and un-XFAIL mutable-vec-drop.rs.
2010-07-23 12:32:12 -07:00
Graydon Hoare
b5e46ac2a0
Two more testcases for overwriting already-live box-like fields in structures, without leaking.
2010-07-23 12:22:31 -07:00
Roy Frostig
1730d2e037
Notify copy glue of dst-initialization and fix _vec.alloc issues in lib and runtime. Closes #109 .
2010-07-22 17:47:32 -07:00
Graydon Hoare
ede42cf931
A certain incomplete quantity of wrestling with "INIT" statements that don't actually initialize. Should probably rename them to MAKE. Anyway, WIP, but two steps forward (and one back). More later.
2010-07-22 17:05:45 -07:00
Graydon Hoare
0f220ecae9
Beat up on the preempt test a bit more, as it keeps hanging under valgrind.
2010-07-22 15:05:35 -07:00
Roy Frostig
3708865906
Re-introduce bits of vec-lib test that blocked on now-fixed issue #108 .
2010-07-22 12:49:11 -07:00
Graydon Hoare
eaa35611dc
Add XFAIL'ed test for return-in-iter, call unimpl when we find it. Closes #100 .
2010-07-22 12:24:55 -07:00
Graydon Hoare
c96634af4b
Fix mem op= mem bug in trans.ml (via not terribly good fix). Closes #111 .
2010-07-22 12:11:39 -07:00
Roy Frostig
c69ec53dc5
Remove explicit deref workaround in dtor-order test. No longer necessary.
2010-07-20 09:15:23 -07:00
Roy Frostig
ae515c017c
ctxt_auto_deref_lval decides whether to autoderef the entire lval, not its base.
2010-07-19 19:06:55 -07:00
Roy Frostig
fde9ca0937
Autoderef objects when passing them as implicit (indirect) arg upon vtbl-dispatch. Add testcase and XFAIL it on LLVM. Closes #112 .
2010-07-19 18:25:26 -07:00