about summary refs log tree commit diff
path: root/src/lib/vec.rs
AgeCommit message (Collapse)AuthorLines
2011-08-20ReformatBrian Anderson-58/+51
This changes the indexing syntax from .() to [], the vector syntax from ~[] to [] and the extension syntax from #fmt() to #fmt[]
2011-08-19Add an iter2 iterator to vec.Michael Sullivan-0/+8
2011-08-17Remove last mentions of vec<> type in Rust sourceBrian Anderson-8/+0
2011-08-16Port the stdlib to the expr foo::<T> syntax.Erick Tryzelaar-11/+11
2011-08-16Port the stdlib to the decl foo<T> syntax.Erick Tryzelaar-49/+49
2011-08-16Port the stdlib to the typaram foo<T> syntax.Erick Tryzelaar-8/+8
2011-08-16Rename std::ivec to std::vecBrian Anderson-0/+355
2011-08-12Remove std::vecBrian Anderson-21/+0
2011-08-12Remove runtime vector builtinsBrian Anderson-20/+0
2011-08-12Don't export anything from std::vecBrian Anderson-2/+2
2011-08-12Remove last use of vec:bufBrian Anderson-5/+0
2011-08-12Remove last uses of vec::lenBrian Anderson-3/+0
2011-08-12Remove unused functions from std::vecBrian Anderson-316/+0
2011-08-12Remove more exports from std::vecBrian Anderson-9/+1
2011-08-12Hide even more exports from std::vecBrian Anderson-5/+1
2011-08-12Remove a bunch of exports from std::vecBrian Anderson-7/+0
2011-08-12Don't export vec::alloc, vec::refcountBrian Anderson-2/+0
2011-08-12Limit the exports from std::vecBrian Anderson-0/+25
2011-08-01Partially implement destructuring localsMarijn Haverbeke-1/+1
You can now say let {bcx, val} = some_result_returner(); Similar for loop variables. Assigning to such variables is not safe yet. Function arguments also remain a TODO.
2011-07-29Turn on kind propagation for typarams. Annotate a bunch of typarams in rustc ↵Graydon Hoare-32/+33
and libstd.
2011-07-27Don't allow globals or immutable locals to be passed by mut aliasMarijn Haverbeke-1/+1
Closes #747
2011-07-27Reformat for new syntaxMarijn Haverbeke-171/+155
2011-07-26Remove all uses of tuples from the compiler and stdlibMarijn Haverbeke-11/+11
2011-07-13Prohibit trailing whitespace under 'tidy' script. Clean up all caught cases.Graydon Hoare-2/+2
2011-07-07Make moving of temporaries do the right thing, use it to optimizeMarijn Haverbeke-4/+1
This adds support for dropping cleanups for temporary values when they are moved somewhere else. It then adds wraps most copy operations (return, put in data structure, box, etc) in a way that will fall back to a move when it is safe. This saves a lot of taking/dropping, shaving over a megabyte off the stage2/rustc binary size. In some cases, most notably function returns, we could detect that the returned value is a local variable, and can thus be safely moved even though it is not a temporary. This will require putting some more information in lvals. I did not yet handle function arguments, since the logic for passing them looked too convoluted to touch. I'll probably try that in the near future, since it's bound to be a big win.
2011-07-05Move everything syntax-related to syntax/, break deps on rest of compilerMarijn Haverbeke-0/+13
src/comp/syntax is currently just a sub-module of rustc, but it will, in the near future, be its own crate. This includes: - The AST data structure - The parser - The pretty-printer - Visit, walk, and fold - The syntax extension system - Some utility stuff that should be in the stdlib* *) Stdlib extensions currently require a snapshot before they can be used, and the win build is very broken right now. This is temporary and will be cleaned up when one of those problems goes away. A lot of code was moved by this patch, mostly towards a more organized layout. Some package paths did get longer, and I guess the new layout will take some getting used to. Sorry about that! Please try not to re-introduce any dependencies in syntax/ on any of the other src/comp/ subdirs.
2011-06-28Comments.Lindsey Kuper-0/+2
2011-06-28Add simple syntax extension (#simplext)Paul Stansifer-0/+18
2011-06-24Invalidate constraints correctly after an assignment expressionTim Chevalier-1/+1
Modified typestate to throw away any constraints mentioning a variable on the LHS of an assignment, recv, assign_op, or on either side of a swap. Some code cleanup as well.
2011-06-24Remove res idents from stdlibMarijn Haverbeke-18/+18
2011-06-15Fix a bunch of compile-command lines to use RBUILDGraydon Hoare-1/+1
2011-06-15Reformat source tree (minus a couple tests that are still grumpy).Graydon Hoare-172/+79
2011-06-15Fix assignments to immutable fields throughout the codeMarijn Haverbeke-2/+2
2011-06-10Fix unsafe uses of mutable referencesMarijn Haverbeke-0/+8
2011-06-10Fix all occurrences of writing to immutable aliasesMarijn Haverbeke-2/+2
You'd be surprised.
2011-06-09Further support for predicate constraintsTim Chevalier-0/+15
Changed function types to include a list of constraints. Added code for parsing and pretty-printing constraints. This necessitated splitting pprust into two files (pprust and ppaux) to break a circulate dependency, as ty_to_str now needs to print out constraints, which may include literals, but pprust depended on ty.
2011-06-09Add vec::memberMarijn Haverbeke-0/+7
2011-06-09Some more workarounds to please the alias checkerMarijn Haverbeke-6/+6
Some of the vec utilities now only work on immutable vecs, since they would have to be rewritten to do a lot more copying to be alias-safe. Some forced copying was added to map.rs, showing a weakness in the alias checker (or maybe the alias system): when fn args are passed into a function, calling them must assume all aliases that are not immutably rooted (directly connected to a local or temporary without any mutable edges) become invalid. This will be a drag on functional programming in Rust. Work around alias issues in the stdlib
2011-06-07rustc: Use a set-based approach to unification; remove ty_bound_param and ↵Patrick Walton-2/+8
ty_local. Sorry, big perf regression; will fix soon.
2011-06-06Begin tidying up name-mangling rules.Graydon Hoare-0/+6
2011-06-03rustc: Add a "smallintmap" implementationPatrick Walton-0/+13
2011-06-02Fix and un-xfail vec-append testMarijn Haverbeke-2/+3
2011-05-31stdlib: Remove unneeded type params from alt patternsBrian Anderson-6/+6
2011-05-27Added filter_map.Paul Stansifer-4/+16
2011-05-19Added two version of reverse and a swap function to the standard library.Eric Holk-0/+39
2011-05-19stdlib: Add vec growth functions that use a thunk to initialize elementsPatrick Walton-0/+14
2011-05-17Finally rename std::_xxx to std::xxxMarijn Haverbeke-0/+318
Except for _task, which is still a keyword.