about summary refs log tree commit diff
path: root/src/libstd/io.rs
AgeCommit message (Collapse)AuthorLines
2013-06-13Revert "std: convert {vec,str}::to_owned to methods."Brian Anderson-1/+1
This fixes the strange random crashes in compile-fail tests. This reverts commit 96cd61ad034cc9e88ab6a7845c3480dbc1ea62f3. Conflicts: src/librustc/driver/driver.rs src/libstd/str.rs src/libsyntax/ext/quote.rs
2013-06-12std: unify the str -> [u8] functions as 3 methods: .as_bytes() and ↵Huon Wilson-2/+2
.as_bytes_with_null[_consume](). The first acts on &str and is not nul-terminated, the last two act on strings that are always null terminated (&'static str, ~str and @str).
2013-06-12std: convert {vec,str}::to_owned to methods.Huon Wilson-1/+1
2013-06-11fix tests, remove some warningsHuon Wilson-1/+0
2013-06-11std: replace str::{starts,ends}_with with the method.Huon Wilson-2/+2
2013-06-10std: convert str::char_at* to methods.Huon Wilson-1/+1
2013-06-10std: remove str::{len, slice, is_empty} in favour of methods.Huon Wilson-1/+1
2013-06-04librustc: Disallow multiple patterns from appearing in a "let" declaration.Patrick Walton-3/+5
You can still initialize multiple variables at once with "let (x, y) = (1, 2)".
2013-06-04std::io: Modernize some constructorsPhilipp Brüschweiler-33/+35
Part of #3853
2013-05-30Remove copy bindings from patterns.Niko Matsakis-3/+3
2013-05-30Require documentation by default for libstdAlex Crichton-0/+2
Adds documentation for various things that I understand. Adds #[allow(missing_doc)] for lots of things that I don't understand.
2013-05-28auto merge of #6771 : thestinger/rust/highlight, r=luqmanabors-10/+15
This works with pandoc linked against highlighting-kate >= 0.5.3.8. It seems to just be a no-op with earlier versions, because I successfully ran this through `try`. This also fixes some consistency issues (like making `Example`/`Examples` always a header and always using three tildes).
2013-05-27syntax highlight code examples in docstringsDaniel Micay-10/+15
2013-05-28Remove unnecessary allocations flagged by lintSeo Sanghyeon-3/+3
2013-05-23cleanup warnings from libstdErick Tryzelaar-14/+14
2013-05-22libstd: Rename libcore to libstd and libstd to libextra; update makefiles.Patrick Walton-0/+2105
This only changes the directory names; it does not change the "real" metadata names.
2012-03-12Libc/os/run/rand/io reorganization. Close #1373. Close #1638.Graydon Hoare-750/+0
- Move io, run and rand to core. - Remove incorrect ctypes module (use libc). - Remove os-specific modules for os and fs. - Split fs between core::path and core::os.
2012-03-10Use loop instead of while(true) in libraries and compiler itselfTim Chevalier-2/+2
And remove spurious fails/unreachable() calls.
2012-03-02comp/std: rename io::string_reader to io::str_reader.Erick Tryzelaar-5/+5
2012-03-02std: add a io::with_str_reader fn to remove a str copyErick Tryzelaar-7/+24
2012-02-28core/std: whitespace fixes.Erick Tryzelaar-2/+3
2012-02-28std: Add helpers to simplify making str io::writersErick Tryzelaar-0/+13
2012-02-24Encode/decode AST into metadata, re-instantiate inlined itemsNiko Matsakis-8/+52
2012-02-09Remove some pointless importsMarijn Haverbeke-2/+2
2012-02-09Increase precedence of as operatorMarijn Haverbeke-5/+5
Closes #1717
2012-02-01Remove native types from stdlibMarijn Haverbeke-10/+10
2012-01-31Change option::t to optionTim Chevalier-4/+4
Now that core exports "option" as a synonym for option::t, search-and- replace option::t with option. The only place that still refers to option::t are the modules in libcore that use option, because fixing this requires a new snapshot (forthcoming).
2012-01-25(TEMPORARY) Break something by making io::mem_buffer_str UTF-8 safeKevin Cantu-1/+1
2012-01-25Replacing str::unsafe_from_bytes with str::from_bytes (part 6)Kevin Cantu-1/+4
2012-01-25Replacing str::unsafe_from_bytes with str::from_bytes (part 5)Kevin Cantu-3/+3
2012-01-23s/block()/fn()/gNiko Matsakis-3/+3
2012-01-19lib: ";" to "," in enumsPatrick Walton-5/+5
2012-01-19stdlib: "tag" -> "enum"Patrick Walton-3/+3
2012-01-18Remove '.' after nullary tags in patternsTim Chevalier-11/+11
Does what it says on the tin. The next commit will remove support for this syntax.
2012-01-17libstd: Move std tests into libstdBrian Anderson-0/+99
2012-01-13deprecate fn exprs and the fn() type, preferring fn@ and native fnNiko Matsakis-4/+4
2012-01-11Major clean-up of std::ioMarijn Haverbeke-283/+204
Use ifaces instead of objs, stop wrapping everything in two (or three) layers of no-value-added indirection, and remove some of the more pointless/outdated idioms from the code.
2012-01-09add tests for io::readchars and io::readcharGrahame Bowland-7/+10
Additionally reformat so that 'make check' passes.
2012-01-09add new read_chars method, fix bug in read_charGrahame Bowland-20/+60
having a read_chars method is convenient and more efficient. the old read_char method had a bug due to re-use of the 'w' width variable as a loop counter and so was broken for wide characters, this patch fixes that.
2011-12-28libstd: add bytes_reader and bytes_writerErick Tryzelaar-5/+24
This parallels nicely with string_reader and string_writer, but working with raw byte strings. I'm not quite sure if the return type for bytes_writer.get_bytes should be [u8] or [mutable u8] though, so I'm arbitrarily picking mutable for now.
2011-12-28libstd: Allow io writer to write mutable arraysErick Tryzelaar-6/+6
2011-12-22Register new snapshots, purge log_err and log_full in favour of log(...).Graydon Hoare-2/+2
2011-12-22Register snapshots and switch logging over to use of log_full or #error / ↵Graydon Hoare-7/+7
#debug.
2011-12-19preparing for removing math from stdStefan Plantikow-2/+2
2011-12-13Copy first batch of material from libstd to libcore.Graydon Hoare-0/+2
2011-12-06libstd: Update docsBrian Anderson-0/+6
2011-12-06Establish 'core' library separate from 'std'.Graydon Hoare-0/+582