about summary refs log tree commit diff
path: root/src/libcore/str.rs
AgeCommit message (Collapse)AuthorLines
2013-03-14core: Add to_bytes method to StrSlice traitBrian Anderson-0/+3
2013-03-11Remove uses of logBrian Anderson-5/+4
2013-03-11libsyntax: Stop parsing bare functions in preparation for switching them overPatrick Walton-3/+9
2013-03-11librustc: Replace all uses of `fn()` with `&fn()`. rs=defunPatrick Walton-47/+47
2013-03-07test: Fix tests.Patrick Walton-10/+19
2013-03-07librustc: Convert all uses of `assert` over to `fail_unless!`Patrick Walton-366/+370
2013-03-06Add manual &self/ and &static/ and /&self declarations thatNiko Matsakis-6/+6
are currently inferred. New rules are coming that will require them to be explicit. All add some explicit self declarations.
2013-03-05auto merge of #5234 : pcwalton/rust/equiv, r=pcwaltonbors-1/+7
r? @nikomatsakis
2013-03-05libcore: Implement an `Equiv` trait and use it on hashmaps.Patrick Walton-1/+7
7.3x speedup in string map search speed on a microbenchmark of pure hashmap searching against a constant string, due to the lack of allocations. I ran into a few snags. 1. The way the coherence check is set up, I can't implement `Equiv<@str>` and `Equiv<~str>` for `&str` simultaneously. 2. I wanted to implement `Equiv<T>` for all `T:Eq` (i.e. every type can be compared to itself if it implements `Eq`), but the coherence check didn't like that either. 3. I couldn't add this to the `Map` trait because `LinearMap` needs special handling for its `Q` type parameter: it must not only implement `Equiv<T>` but also `Hash` and `Eq`. 4. `find_equiv(&&"foo")` doesn't parse, because of the double ampersand. It has to be written `find_equiv(& &"foo")`. We can probably just fix this. Nevertheless, this is a huge win; it should address a major source of performance problems, including the one here: http://maniagnosis.crsr.net/2013/02/creating-letterpress-cheating-program.html
2013-03-05auto merge of #5233 : bstrie/rust/deimpselfcore, r=graydonbors-65/+79
2013-03-04De-implicit-self libcoreBen Striegel-65/+79
2013-03-04Adding missing imports for tests, and gate off othersAlex Crichton-1/+3
2013-03-04Remove unused imports throughout src/Alex Crichton-3/+0
2013-03-02auto merge of #5196 : thestinger/rust/ord, r=catamorphismbors-1/+39
This allows `TreeMap`/`TreeSet` to fully express their requirements and reduces the comparisons from ~1.5 per level to 1 which really helps for string keys. I also added `ReverseIter` to the prelude exports because I forgot when I originally added it.
2013-03-02add a TotalOrd traitDaniel Micay-1/+39
2013-02-28core: Address XXX, make static constants for strings used when stringifying ↵Tim Chevalier-0/+7
floats
2013-02-28Fix implicit leaks of imports throughout librariesAlex Crichton-0/+1
Also touch up use of 'pub' and move some tests around so the tested functions don't have to be 'pub'
2013-02-27librustc: Forbid `pub` or `priv` before trait implementationsPatrick Walton-1/+1
2013-02-26Move levenshtein distance fn to core::str.Luqman Aden-0/+34
2013-02-15librustc: Stop parsing `impl Type : Trait` and fix several declarations that ↵Patrick Walton-1/+1
slipped through. r=tjc
2013-02-14libcore: Remove ptr::mut_addr_of since &mut is coerced to *mutLuqman Aden-1/+1
2013-02-14librustc: Replace `impl Type : Trait` with `impl Trait for Type`. ↵Patrick Walton-9/+9
rs=implflipping
2013-02-13Remove die!, raplace invocations with fail! Issue #4524 pt 3Nick Desaulniers-5/+5
2013-02-12Adjust borrow checker algorithm to address #4856 unsoundness,Niko Matsakis-3/+5
and then adjust code to match. rs=unsound (will review post-landing)
2013-02-08Fix subtle error in caching during kind computation that could cause linearNiko Matsakis-0/+21
values to be copied. Rewrite kind computation so that instead of directly computing the kind it computes what kinds of values are present in the type, and then derive kinds based on that. I find this easier to think about. Fixes #4821.
2013-02-07Make ~fn non-copyable, make &fn copyable, split barefn/closure types,Niko Matsakis-3/+15
correct handling of moves for struct-record update. Part of #3678. Fixes #2828, #3904, #4719.
2013-01-31Replace most invocations of fail keyword with die! macroNick Desaulniers-5/+5
2013-01-30librustc: Change `self` as a type to `Self` everywhere. r=brsonPatrick Walton-3/+3
2013-01-24remove remaining is_not_empty functions/methodsDaniel Micay-13/+0
2013-01-23libsyntax: Remove `fn() unsafe { ... }`. r=graydonPatrick Walton-21/+32
2013-01-17librustc: Implement write guards for borrowing `@mut` to `&` or `&mut`. ↵Patrick Walton-8/+8
r=nmatsakis
2013-01-13Merge pull request #4411 from wting/4203_rename_memcpyTim Chevalier-4/+4
Rename memcpy, memmove, memset
2013-01-10libcore: Fix core test. rs=brokenPatrick Walton-6/+10
2013-01-10Rename memcpy, memmove, memset to prevent any confusion with the C equivalents.William Ting-4/+4
Closes #4203.
2013-01-08librustc: Make unqualified identifier searches terminate at the nearest ↵Patrick Walton-1/+7
module scope. r=tjc
2013-01-08Revert "librustc: Make unqualified identifier searches terminate at the ↵Patrick Walton-7/+1
nearest module scope. r=tjc" This reverts commit a8d37af2473da79be704c9ce2374f278c47177b6.
2013-01-08librustc: Make unqualified identifier searches terminate at the nearest ↵Patrick Walton-1/+7
module scope. r=tjc
2012-12-27librustc: Fix the test runner, the condition system, and core test. rs=bustagePatrick Walton-1/+5
2012-12-27librustc: Terminate name searches at the nearest module scope for paths that ↵Patrick Walton-0/+14
contain at least two components. r=graydon
2012-12-23core: Mark some functions as pureChris Peterson-4/+2
2012-12-12core: Remove some uses of 'move'Brian Anderson-31/+31
2012-12-10Add license boilerplate to more files.Graydon Hoare-0/+10
2012-12-09Remove transitional codeBrian Anderson-9/+0
2012-12-04librustc: Implement explicit self for Add and Index; add a hack in the ↵Patrick Walton-0/+9
borrow checker to support this. r=nmatsakis
2012-11-30core: Make core.rc more readable. CleanupBrian Anderson-0/+6
2012-11-28core: Convert some records to structsBrian Anderson-21/+26
2012-11-28Register snapshotsBrian Anderson-78/+0
2012-11-20Remove parentheses from closure argument typesErick Tryzelaar-1/+1
2012-11-19rustc: Implement explicit self for Eq and Ord. r=graydonPatrick Walton-0/+78
2012-11-03Remove stage0 stuff that was awaiting snapshotTim Chevalier-36/+0
and re-register snapshots Just removing unneeded code, no review