aboutsummaryrefslogtreecommitdiff
path: root/src/lib/option.rs
Commit message (Collapse)AuthorAgeFilesLines
* Downcase std modules again, move to :: for module dereferencingMarijn Haverbeke2011-05-121-0/+60
| | | | This should be a snapshot transition.
* Rename std modules to be camelcasedMarijn Haverbeke2011-05-061-60/+0
| | | | (Have fun mergining your stuff with this.)
* Handle nested items correctly in typestate_checkTim Chevalier2011-04-191-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | Summary says it all. Actually, only nested objects and functions are handled, but that's better than before. The fold that I was using before to traverse a crate wasn't working correctly, because annotations have to reflect the number of local variables of the nearest enclosing function (in turn, because annotations are represented as bit vectors). The fold was traversing the AST in the wrong order, first filling in the annotations correctly, but then re-traversing them with the bit vector length for any outer nested functions, and so on. Remedying this required writing a lot of tedious boilerplate code because I scrapped the idea of using a fold altogether. I also made typestate_check handle unary, field, alt, and fail. Also, some miscellaneous changes: * added annotations to blocks in typeck * fix pprust so it can handle spawn * added more logging functions in util.common * fixed _vec.or * added maybe and from_maybe in option * removed fold_block field from ast_fold, since it was never used
* Continued sketching out code for checking states against preconditions.Tim Chevalier2011-04-061-0/+7
| | | | | | | | | It's still sketchy. I added a typestate annotation field to statements tagged stmt_decl or stmt_expr, because a stmt_decl statement has a typestate that's different from that of its child node. This necessitated trivial changes to a bunch of other files all over to the compiler. I also added a few small standard library functions, some of which I didn't actually end up using but which I thought might be useful anyway.
* Add an option.is_none() methodPatrick Walton2011-03-171-0/+7
|
* rustboot: Don't use walk to traverse statements in type.ml; fixes redundant ↵Patrick Walton2010-11-181-0/+2
| | | | checking, improves diagnostics. Also report untyped slots.
* Move the option type to its own modulePatrick Walton2010-11-051-0/+40
|
* Revert "Move the option type to its own module"Patrick Walton2010-11-051-40/+0
|
* Move the option type to its own modulePatrick Walton2010-11-051-0/+40