about summary refs log tree commit diff
path: root/src/libstd/gc.rs
AgeCommit message (Collapse)AuthorLines
2014-10-02std: remove gc module.Eduard Burtescu-156/+0
2014-09-26Rename raw::Box to raw::GcBoxKeegan McAllister-1/+1
Fixes #17470.
2014-06-30libstd: set baseline stability levels.Aaron Turon-0/+1
Earlier commits have established a baseline of `experimental` stability for all crates under the facade (so their contents are considered experimental within libstd). Since `experimental` is `allow` by default, we should use the same baseline stability for libstd itself. This commit adds `experimental` tags to all of the modules defined in `std`, and `unstable` to `std` itself.
2014-06-29Implement RFC#28: Add PartialOrd::partial_cmpSteven Fackler-0/+5
I ended up altering the semantics of Json's PartialOrd implementation. It used to be the case that Null < Null, but I can't think of any reason for an ordering other than the default one so I just switched it over to using the derived implementation. This also fixes broken `PartialOrd` implementations for `Vec` and `TreeMap`. RFC: 0028-partial-cmp
2014-06-29Extract tests from libcore to a separate crateSteven Fackler-0/+7
Libcore's test infrastructure is complicated by the fact that many lang items are defined in the crate. The current approach (realcore/realstd imports) is hacky and hard to work with (tests inside of core::cmp haven't been run for months!). Moving tests to a separate crate does mean that they can only test the public API of libcore, but I don't feel that that is too much of an issue. The only tests that I had to get rid of were some checking the various numeric formatters, but those are also exercised through normal format! calls in other tests.
2014-06-28Rename all raw pointers as necessaryAlex Crichton-2/+2
2014-06-24core: Add stability attributes to CloneBrian Anderson-0/+1
The following are tagged 'unstable' - core::clone - Clone - Clone::clone - impl Clone for Arc - impl Clone for arc::Weak - impl Clone for Rc - impl Clone for rc::Weak - impl Clone for Vec - impl Clone for Cell - impl Clone for RefCell - impl Clone for small tuples The following are tagged 'experimental' - Clone::clone_from - may not provide enough utility - impls for various extern "Rust" fns - may not handle lifetimes correctly See https://github.com/rust-lang/rust/wiki/Meeting-API-review-2014-06-23#clone
2014-06-14Register new snapshotsAlex Crichton-6/+0
2014-06-11rustc: Move the AST from @T to Gc<T>Alex Crichton-10/+9
2014-06-11rustc: Update how Gc<T> is recognizedAlex Crichton-34/+61
This commit uses the same trick as ~/Box to map Gc<T> to @T internally inside the compiler. This moves a number of implementations of traits to the `gc` module in the standard library. This removes functions such as `Gc::new`, `Gc::borrow`, and `Gc::ptr_eq` in favor of the more modern equivalents, `box(GC)`, `Deref`, and pointer equality. The Gc pointer itself should be much more useful now, and subsequent commits will move the compiler away from @T towards Gc<T> [breaking-change]
2014-05-07core: Inhert ~/@/& cmp traits, remove old modulesAlex Crichton-2/+1
This commit removes the std::{managed, reference} modules. The modules serve essentially no purpose, and the only free function removed was `managed::ptr_eq` which can be achieved by comparing references. [breaking-change]
2014-05-02Replace most ~exprs with 'box'. #11779Brian Anderson-1/+1
2014-03-31std: Switch field privacy as necessaryAlex Crichton-4/+4
2014-03-28Convert most code to new inner attribute syntax.Brian Anderson-1/+1
Closes #2569
2014-03-20Remove RefCell::{with, with_mut}Steven Fackler-4/+2
These are superfluous now that we have fixed rvalue lifetimes and Deref.
2014-03-08Removed DeepClone. Issue #12698.Michael Darakananda-22/+1
2014-02-02Fix `@str` removal tests.Huon Wilson-1/+0
2014-01-31Introduce marker types for indicating variance and for opting outNiko Matsakis-5/+7
of builtin bounds. Fixes #10834. Fixes #11385. cc #5922.
2014-01-14add an experimental tag for Gc<T> due to cyclesDaniel Micay-0/+5
This type isn't yet very useful since it only pretends cycles won't be a problem. Anyone using it should be made aware that they're going to leak.
2014-01-09librustc: Implement placement `box` for GC and unique pointers.Patrick Walton-0/+18
2014-01-07Fixed Gc::clone, implemented Gc::ptr_eqkvark-3/+25
2014-01-07stdtest: Fix all leaked trait importsAlex Crichton-0/+1
2013-11-26libstd: Fix Win32 and other bustage.Patrick Walton-4/+4
2013-11-23Move mutable::Mut to cell::RefCellSteven Fackler-7/+7
2013-11-19add an initial `Gc<T>` stub with the APIDaniel Micay-0/+99
2013-08-03std: Remove gc and stackwalkBrian Anderson-358/+0
These are both obsoleted by the forthcoming new GC.
2013-08-02librustc: Disallow "unsafe" for external functionsPatrick Walton-3/+3
2013-08-01std: Replace `for` with `do { .. }` expr in std::gcblake2-ppc-58/+49
Change all users of old-style for with internal iterators to using `do`-loops. The code in stackwalk.rs does not actually implement the looping protocol (no break on return false). The code in gc.rs does not use loop breaks, nor does any code using it. We remove the capacity to break from the loops in std::gc and implement the walks using `do { .. }` expressions. No behavior change.
2013-07-30implement pointer arithmetic with GEPDaniel Micay-6/+6
Closes #8118, #7136 ~~~rust extern mod extra; use std::vec; use std::ptr; fn bench_from_elem(b: &mut extra::test::BenchHarness) { do b.iter { let v: ~[u8] = vec::from_elem(1024, 0u8); } } fn bench_set_memory(b: &mut extra::test::BenchHarness) { do b.iter { let mut v: ~[u8] = vec::with_capacity(1024); unsafe { let vp = vec::raw::to_mut_ptr(v); ptr::set_memory(vp, 0, 1024); vec::raw::set_len(&mut v, 1024); } } } fn bench_vec_repeat(b: &mut extra::test::BenchHarness) { do b.iter { let v: ~[u8] = ~[0u8, ..1024]; } } ~~~ Before: test bench_from_elem ... bench: 415 ns/iter (+/- 17) test bench_set_memory ... bench: 85 ns/iter (+/- 4) test bench_vec_repeat ... bench: 83 ns/iter (+/- 3) After: test bench_from_elem ... bench: 84 ns/iter (+/- 2) test bench_set_memory ... bench: 84 ns/iter (+/- 5) test bench_vec_repeat ... bench: 84 ns/iter (+/- 3)
2013-07-24Convert uses of transmute which don't need itAlex Crichton-8/+8
2013-07-22new snapshotDaniel Micay-14/+1
2013-07-20librustc: Remove `pub extern` and `priv extern` from the language.Patrick Walton-1/+1
Place `pub` or `priv` on individual items instead.
2013-07-13Split mutable methods out of Set and MapSteven Fackler-1/+1
Fixes most of #4989. I didn't add Persistent{Set,Map} since the only persistent data structure is fun_treemap and its functionality is currently too limited to build a trait out of.
2013-07-01rustc: add a lint to enforce uppercase statics.Huon Wilson-0/+1
2013-06-23Remove unused TyDesc parameter from the glue functionsPhilipp Brüschweiler-1/+14
To remove the environment pointer, support for function pointers without an environment argument is needed (i.e. a fixed version of #6661).
2013-06-23Remove rust_call_tydesc_gluePhilipp Brüschweiler-10/+5
Towards #4812. Also includes some minor cleanups.
2013-05-22libstd: Rename libcore to libstd and libstd to libextra; update makefiles.Patrick Walton-0/+371
This only changes the directory names; it does not change the "real" metadata names.