about summary refs log tree commit diff
path: root/src/librustdoc
AgeCommit message (Collapse)AuthorLines
2013-08-13Remove unused automatic cfg bindings Fixes #7169Nick Desaulniers-6/+5
2013-08-12Forbid pub/priv where it has no effectAlex Crichton-4/+4
Closes #5495
2013-08-10std: Transform.find_ -> .findErick Tryzelaar-6/+6
2013-08-10std: Rename Iterator.transform -> .mapErick Tryzelaar-21/+21
cc #5898
2013-08-10Mass rename of .consume{,_iter}() to .move_iter()Erick Tryzelaar-1/+1
cc #7887
2013-08-08Fix more priv falloutCorey Richardson-3/+3
2013-08-07Change const to staticSangeun Kim-43/+43
2013-08-07Change Freeze to StaticSangeun Kim-3/+3
2013-08-07auto merge of #8294 : erickt/rust/map-move, r=bblumbors-7/+7
According to #7887, we've decided to use the syntax of `fn map<U>(f: &fn(&T) -> U) -> U`, which passes a reference to the closure, and to `fn map_move<U>(f: &fn(T) -> U) -> U` which moves the value into the closure. This PR adds these `.map_move()` functions to `Option` and `Result`. In addition, it has these other minor features: * Replaces a couple uses of `option.get()`, `result.get()`, and `result.get_err()` with `option.unwrap()`, `result.unwrap()`, and `result.unwrap_err()`. (See #8268 and #8288 for a more thorough adaptation of this functionality. * Removes `option.take_map()` and `option.take_map_default()`. These two functions can be easily written as `.take().map_move(...)`. * Adds a better error message to `result.unwrap()` and `result.unwrap_err()`.
2013-08-07core: option.map_consume -> option.map_moveErick Tryzelaar-7/+7
2013-08-06remove `extra::iter`Daniel Micay-2/+2
This module provided adaptors for the old internal iterator protocol, but they proved to be quite unreadable and are not generic enough to handle borrowed pointers well. Since Rust no longer defines an internal iteration protocol, I don't think there's going to be any reuse via these adaptors.
2013-08-05Updated std::Option, std::Either and std::ResultMarvin Löbel-34/+34
- 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-03remove obsolete `foreach` keywordDaniel Micay-10/+10
this has been replaced by `for`
2013-08-02librustc: Disallow "unsafe" for external functionsPatrick Walton-4/+15
2013-08-01std: Change `Times` trait to use `do` instead of `for`blake2-ppc-2/+2
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-01migrate many `for` loops to `foreach`Daniel Micay-12/+10
2013-07-29New naming convention for ast::{node_id, local_crate, crate_node_id, ↵Michael Woerister-7/+7
blk_check_mode, ty_field, ty_method}
2013-07-27cleanup .chain and .chain_err + fixing other filesmaikklein-16/+10
2013-07-24Change 'print(fmt!(...))' to printf!/printfln! in src/lib*Birunthan Mohanathas-3/+2
2013-07-22Ast spanned<T> refactoring, renaming: crate, local, blk, crate_num, crate_cfg.Michael Woerister-14/+14
`crate => Crate` `local => Local` `blk => Block` `crate_num => CrateNum` `crate_cfg => CrateConfig` Also, Crate and Local are not wrapped in spanned<T> anymore.
2013-07-20syntax: modernise attribute handling in syntax::attr.Huon Wilson-71/+68
This does a number of things, but especially dramatically reduce the number of allocations performed for operations involving attributes/ meta items: - Converts ast::meta_item & ast::attribute and other associated enums to CamelCase. - Converts several standalone functions in syntax::attr into methods, defined on two traits AttrMetaMethods & AttributeMethods. The former is common to both MetaItem and Attribute since the latter is a thin wrapper around the former. - Deletes functions that are unnecessary due to iterators. - Converts other standalone functions to use iterators and the generic AttrMetaMethods rather than allocating a lot of new vectors (e.g. the old code would have to allocate a new vector to use functions that operated on &[meta_item] on &[attribute].) - Moves the core algorithm of the #[cfg] matching to syntax::attr, similar to find_inline_attr and find_linkage_metas. This doesn't have much of an effect on the speed of #[cfg] stripping, despite hugely reducing the number of allocations performed; presumably most of the time is spent in the ast folder rather than doing attribute checks. Also fixes the Eq instance of MetaItem_ to correctly ignore spaces, so that `rustc --cfg 'foo(bar)'` now works.
2013-07-18Silence various warnings in bootstrap build.Felix S. Klock II-7/+0
2013-07-17librustc: Remove all uses of the `Copy` bound.Patrick Walton-5/+6
2013-07-17librustc: Remove all uses of "copy".Patrick Walton-307/+287
2013-07-17librustc: Add a lint mode for unnecessary `copy` and remove a bunch of them.Patrick Walton-23/+22
2013-07-17Clean-up tests after debug!/std-macros change.Huon Wilson-31/+57
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-16syntax: make a macros-injection pass; conditionally define debug! to a noop ↵Huon Wilson-0/+2
based on cfg(debug). Macros can be conditionally defined because stripping occurs before macro expansion, but, the built-in macros were only added as part of the actual expansion process and so couldn't be stripped to have definitions conditional on cfg flags. debug! is defined conditionally in terms of the debug config, expanding to nothing unless the --cfg debug flag is passed (to be precise it expands to `if false { normal_debug!(...) }` so that they are still type checked, and to avoid unused variable lints).
2013-07-09auto merge of #7117 : jensnockert/rust/freestanding, r=cmrbors-1/+2
The free-standing functions in f32, f64, i8, i16, i32, i64, u8, u16, u32, u64, float, int, and uint are replaced with generic functions in num instead. This means that instead of having to know everywhere what the type is, like ~~~ f64::sin(x) ~~~ You can simply write code that uses the type-generic versions in num instead, this works for all types that implement the corresponding trait in num. ~~~ num::sin(x) ~~~ Note 1: If you were previously using any of those functions, just replace them with the corresponding function with the same name in num. Note 2: If you were using a function that corresponds to an operator, use the operator instead. Note 3: This is just https://github.com/mozilla/rust/pull/7090 reopened against master.
2013-07-08Bump version numbers to 0.8-preBrian Anderson-1/+1
2013-07-08 Replaces the free-standing functions in f32, &c.Jens Nockert-1/+2
The free-standing functions in f32, f64, i8, i16, i32, i64, u8, u16, u32, u64, float, int, and uint are replaced with generic functions in num instead. If you were previously using any of those functions, just replace them with the corresponding function with the same name in num. Note: If you were using a function that corresponds to an operator, use the operator instead.
2013-07-07remove some method resolve workaroundsDaniel Micay-2/+2
2013-07-07Fix rustdoc and rustiJames Miller-6/+5
2013-07-04Remove standalone comparison functions in vec, make the trait impls better.Huon Wilson-8/+5
2013-07-04Remove vec::{filter, filtered, filter_map, filter_mapped}, replaced by ↵Huon Wilson-125/+58
iterators.
2013-07-01rustc: add a lint to enforce uppercase statics.Huon Wilson-3/+3
2013-06-30auto merge of #7487 : huonw/rust/vec-kill, r=cmrbors-35/+31
Continuation of #7430. I haven't removed the `map` method, since the replacement `v.iter().transform(f).collect::<~[SomeType]>()` is a little ridiculous at the moment.
2013-06-30Bump version from 0.7-pre to 0.7Brian Anderson-1/+1
2013-06-30Remove vec::{map, mapi, zip_map} and the methods, except for .map, since thisHuon Wilson-35/+31
is very common, and the replacement (.iter().transform().collect()) is very ugly.
2013-06-29Great renaming: propagate throughout the rest of the codebaseCorey Richardson-88/+42
2013-06-28librustc: Remove the broken overloaded assign-ops from the language.Patrick Walton-6/+6
They evaluated the receiver twice. They should be added back with `AddAssign`, `SubAssign`, etc., traits.
2013-06-28librustc: Change "Owned" to "Send" everywherePatrick Walton-2/+2
2013-06-28librustc: Rename Const to FreezePatrick Walton-2/+2
2013-06-25Change finalize -> drop.Luqman Aden-1/+1
2013-06-25Rename all files with the 'rc' extensionAlex Crichton-0/+0
2013-06-23Support foreign 'static mut' variables as wellAlex Crichton-1/+1
2013-06-23Add 'static mut' items to the languageAlex Crichton-2/+2
2013-06-23vec: remove BaseIter implementationDaniel Micay-8/+9
I removed the `static-method-test.rs` test because it was heavily based on `BaseIter` and there are plenty of other more complex uses of static methods anyway.
2013-06-22Merge pull request #7270 from thestinger/docDaniel Micay-6/+6
accumulated doc pull requests from the queue
2013-06-21replace vec::find with the IteratorUtil methodDaniel Micay-10/+9
2013-06-21vec: rm old_iter implementations, except BaseIterDaniel Micay-5/+6
The removed test for issue #2611 is well covered by the `std::iterator` module itself. This adds the `count` method to `IteratorUtil` to replace `EqIter`.