diff options
| author | bors <bors@rust-lang.org> | 2013-05-14 10:10:54 -0700 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2013-05-14 10:10:54 -0700 |
| commit | 767e3ae86cba26437a60009d79ac2a295b41768e (patch) | |
| tree | 8f3f8634548c02309d281d6cdbfd7b34b7ea8c9d /src/libstd | |
| parent | 27c228fad7d94a500866696f8c48ef1707a2507b (diff) | |
| parent | ffcc680f9cc26b5b2cb2f453a89dbcf8144f8b9b (diff) | |
| download | rust-767e3ae86cba26437a60009d79ac2a295b41768e.tar.gz rust-767e3ae86cba26437a60009d79ac2a295b41768e.zip | |
auto merge of #6434 : alexcrichton/rust/less-implicit-vecs, r=bstrie
This closes #5204 and #6421. This also removes the `vecs_implicitly_copyable` lint (although now reading #6421, this may not be desired?). If we want to leave it in, it at least removes it from the compiler.
Diffstat (limited to 'src/libstd')
| -rw-r--r-- | src/libstd/rl.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libstd/rl.rs b/src/libstd/rl.rs index 81152430e78..d15a8fc0136 100644 --- a/src/libstd/rl.rs +++ b/src/libstd/rl.rs @@ -28,7 +28,7 @@ pub mod rustrt { } /// Add a line to history -pub unsafe fn add_history(line: ~str) -> bool { +pub unsafe fn add_history(line: &str) -> bool { do str::as_c_str(line) |buf| { rustrt::linenoiseHistoryAdd(buf) == 1 as c_int } @@ -40,21 +40,21 @@ pub unsafe fn set_history_max_len(len: int) -> bool { } /// Save line history to a file -pub unsafe fn save_history(file: ~str) -> bool { +pub unsafe fn save_history(file: &str) -> bool { do str::as_c_str(file) |buf| { rustrt::linenoiseHistorySave(buf) == 1 as c_int } } /// Load line history from a file -pub unsafe fn load_history(file: ~str) -> bool { +pub unsafe fn load_history(file: &str) -> bool { do str::as_c_str(file) |buf| { rustrt::linenoiseHistoryLoad(buf) == 1 as c_int } } /// Print out a prompt and then wait for input and return it -pub unsafe fn read(prompt: ~str) -> Option<~str> { +pub unsafe fn read(prompt: &str) -> Option<~str> { do str::as_c_str(prompt) |buf| { let line = rustrt::linenoise(buf); |
