about summary refs log tree commit diff
path: root/src/libstd/rt
AgeCommit message (Collapse)AuthorLines
2013-10-08Make std::rt::io::extensions publicSteven Fackler-1/+1
This works around #9779, but is probably the right thing to do anyways since that's the module where all of the documentation for those traits lives.
2013-10-08rm useless fast_ffi attributesDaniel Micay-10/+0
this is no longer used by the compiler
2013-10-07Fix existing privacy/visibility violationsAlex Crichton-5/+26
This commit fixes all of the fallout of the previous commit which is an attempt to refine privacy. There were a few unfortunate leaks which now must be plugged, and the most horrible one is the current `shouldnt_be_public` module now inside `std::rt`. I think that this either needs a slight reorganization of the runtime, or otherwise it needs to just wait for the external users of these modules to get replaced with their `rt` implementations. Other fixes involve making things pub which should be pub, and otherwise updating error messages that now reference privacy instead of referencing an "unresolved name" (yay!).
2013-10-06auto merge of #9593 : fhahn/rust/logging-unsafe-removal, r=alexcrichtonbors-202/+305
This pull request changes to memory layout of the `CrateMap` struct to use static slices instead of raw pointers. Most of the discussion took place [here](https://github.com/fhahn/rust/commit/63b5975efa10af7df3df0a50d8d7f9c8d5bcf9e9#L1R92) . The memory layout of CrateMap changed, without bumping the version number in the struct. Another, more backward compatible, solution would be to keep the old code and increase the version number in the new struct. On the other hand, the `annihilate_fn` pointer was removed without bumping the version number recently. At the moment, the stage0 compiler does not use the new memory layout, which would lead the segfaults during stage0 compilation, so I've added a dummy `iter_crate_map` function for stage0, which does nothing. Again, this could be avoided if we'd bump the version number in the struct and keep the old code. I'd like to use a normal `for` loop [here](https://github.com/fhahn/rust/compare/logging-unsafe-removal?expand=1#L1R109), for child in children.iter() { do_iter_crate_map(child, |x| f(x), visited); } but for some reason this only yields `error: unresolved enum variant, struct or const 'Some'` and I have no idea why.
2013-10-06get_crate_map returns an OptionFlorian Hahn-23/+42
2013-10-05Make a task name use a `SendStr`, allowing for eitherMarvin Löbel-2/+2
static or owned strings
2013-10-05Add code for older crate map versions, bumped crate map version numberFlorian Hahn-38/+171
2013-10-05Use &'self str instead of raw char pointer in ModEntryFlorian Hahn-127/+99
2013-10-05Use slice representation for module entries in CrateMapFlorian Hahn-87/+47
Relaxe lifetime of CrateMap as well.
2013-10-05Use slice representation for child crate mapsFlorian Hahn-116/+135
2013-10-05rt::io::net::tcp: Fix eof_twice tests on Win32klutzy-6/+20
cc #8811
2013-10-05std::rt: Add NotConnected to IoErrorKindklutzy-0/+5
2013-10-05std::rt::uv::net: Handle `read_start` errorklutzy-2/+13
cc #9605
2013-10-03Document logging and remove old functionsAlex Crichton-19/+2
This adds a large doc-block to the top of the std::logging module explaining how to use it. This is mostly just making sure that all the information in the manual's section about logging is also here (in case someone decides to look into this module first). This also removes the old console_{on,off} methods. As far as I can tell, the functions were only used by the compiler, and there's no reason for them to be used because they're all turned off by default anyway (maybe they were turned on by default at some point...) I believe that this is the final nail in the coffin and closes #5021
2013-10-03Close out #9155Steven Fackler-13/+9
Add a test to make sure it works and switch a private struct over to a newtype. Closes #9155
2013-10-02Stop using newtype wrappers in std::rt::ioSteven Fackler-30/+48
UnboundedPipeStream is still a newtype since process::set_stdio needs to look into its internals. Closes #9667
2013-10-02auto merge of #9665 : alexcrichton/rust/snapshot, r=brsonbors-2/+2
Uses the new snapshots to kill the old `loop` and introduce the new `continue`.
2013-10-01auto merge of #9578 : alexcrichton/rust/un-ignore-libuv-process-tests, r=brsonbors-142/+2
Closes #9341
2013-10-01Move the rt::io::process tests to run-passAlex Crichton-142/+2
Closes #9341
2013-10-01Migrate users of 'loop' to 'continue'Alex Crichton-2/+2
Closes #9467
2013-09-30std: Remove usage of fmt!Alex Crichton-191/+179
2013-09-30std::rt::uv::net: Enable tests on Win32klutzy-4/+0
Closes #8815.
2013-09-29Put a newline after each logging messageAlex Crichton-1/+1
2013-09-27auto merge of #9574 : FlaPer87/rust/suppress_warnings, r=metajackbors-1/+0
Small change that suppresses a warning because of an unused import.
2013-09-27auto merge of #9562 : alexcrichton/rust/snapshots, r=thestingerbors-12/+0
2013-09-27auto merge of #9559 : sfackler/rust/more-visibility, r=alexcrichtonbors-11/+11
2013-09-27Suppress warning by removing unused importFlavio Percoco-1/+0
2013-09-27Register new snapshotsAlex Crichton-12/+0
2013-09-26std: removed some warnings in tests.Erick Tryzelaar-6/+5
2013-09-26std and rustc: Convert users of c_str to use .with_c_strErick Tryzelaar-16/+16
2013-09-26Visibility fixesSteven Fackler-11/+11
2013-09-26auto merge of #9261 : alexcrichton/rust/logging, r=huonwbors-31/+22
This lifts various restrictions on the runtime, for example the character limit when logging a message. Right now the old debug!-style macros still involve allocating (because they use fmt! syntax), but the new debug2! macros don't involve allocating at all (unless the formatter for a type requires allocation.
2013-09-26auto merge of #9507 : brson/rust/sched, r=alexcrichtonbors-28/+140
This also includes a fix for yielding from single-threaded schedulers where the scheduler would stop working before its work queue was empty. Fixes the deadlocks that this patch had previously.
2013-09-26auto merge of #9506 : sfackler/rust/visibility, r=alexcrichtonbors-2/+2
2013-09-26auto merge of #9490 : alexcrichton/rust/issue-9487, r=cmrbors-6/+10
If there's no TLS key just yet, then there's nothing to unsafely borrow, so continue returning None. This prevents causing the runtime to abort itself when logging before the runtime is fully initialized. Closes #9487 r? @brson
2013-09-25std::rt: Implement task yielding. Fix a starvation problemBrian Anderson-28/+140
2013-09-25Some struct visibility fixesSteven Fackler-2/+2
2013-09-25Refactor the logging system for fewer allocationsAlex Crichton-31/+22
This lifts various restrictions on the runtime, for example the character limit when logging a message. Right now the old debug!-style macros still involve allocating (because they use fmt! syntax), but the new debug2! macros don't involve allocating at all (unless the formatter for a type requires allocation.
2013-09-25rustdoc: Change all code-blocks with a scriptAlex Crichton-18/+18
find src -name '*.rs' | xargs sed -i '' 's/~~~.*{\.rust}/```rust/g' find src -name '*.rs' | xargs sed -i '' 's/ ~~~$/ ```/g' find src -name '*.rs' | xargs sed -i '' 's/^~~~$/ ```/g'
2013-09-25Don't die in try_unsafe_borrow if tls isn't readyAlex Crichton-6/+10
If there's no TLS key just yet, then there's nothing to unsafely borrow, so continue returning None. This prevents causing the runtime to abort itself when logging before the runtime is fully initialized. Closes #9487
2013-09-24auto merge of #9470 : luqmana/rust/bba, r=brsonbors-17/+14
#8431 ~~@brson: do we need to bump up the cratemap version for this change?~~ Tis a no.
2013-09-24Remove the annihilate function from the crate map. Fixes #8431Luqman Aden-17/+14
2013-09-24auto merge of #9336 : alexcrichton/rust/issue-7981, r=catamorphismbors-2/+2
Progress on #7981 This doesn't completely close the issue because `struct A;` is still allowed, and it's a much larger change to disallow that. I'm also not entirely sure that we want to disallow that. Regardless, punting that discussion to the issue instead.
2013-09-24Stop accepting 'impl ...;', require {} insteadAlex Crichton-2/+2
Progress on #7981
2013-09-23Register new snapshotsAlex Crichton-50/+4
2013-09-23auto merge of #9301 : luqmana/rust/ncm, r=brsonbors-2/+87
Get rid of the crate_map arg! r? @brson
2013-09-23Find the cratemap at runtime on windows.Luqman Aden-2/+21
2013-09-22disable starvation test completely for nowDaniel Micay-13/+10
this is still broken on the bsd builder, perhaps because it has 1 core
2013-09-22disable scheduler starvation test on valgrindDaniel Micay-9/+13
2013-09-23std: merge rand::{Rng,RngUtil} with default methods.Huon Wilson-4/+4
Also, documentation & general clean-up: - remove `gen_char_from`: better served by `sample` or `choose`. - `gen_bytes` generalised to `gen_vec`. - `gen_int_range`/`gen_uint_range` merged into `gen_integer_range` and made to be properly uniformly distributed. Fixes #8644. Minor adjustments to other functions.