Commit Graph

13595 Commits

Author SHA1 Message Date
Daniel Micay
ed45354a95 remove old StdMap trait
this has been replaced by core::container::Map
2013-02-03 15:55:09 -05:00
Daniel Micay
a06ef7424c cat modernization (cleanup of a run-pass test) 2013-02-03 15:55:09 -05:00
Daniel Micay
0a75aefad0 update compile-fail/map-types.rs to use hashmap 2013-02-03 15:55:09 -05:00
bors
2846e033d7 automated merge 2013-02-02 16:08:40 -08:00
Brian Anderson
8ebdb1a11b rt: Remove some unused upcalls 2013-02-01 21:58:33 -08:00
Brian Anderson
a50d1fdbda rt: Remove get_frame_glue_fns. Unused 2013-02-01 21:22:49 -08:00
Brian Anderson
02fbd5a164 rt: Remove circular_buffer 2013-02-01 21:22:49 -08:00
Brian Anderson
4f6516969e rt: Remove ports 2013-02-01 21:22:49 -08:00
Brian Anderson
542bf20414 core: Remove oldcomm 2013-02-01 21:22:49 -08:00
Brian Anderson
5633783f47 rustdoc: Convert to pipes 2013-02-01 21:22:49 -08:00
Brian Anderson
90f00a1c37 rustdoc: Remove stray mode 2013-02-01 21:22:49 -08:00
Brian Anderson
b80d711912 rustdoc: Remove another use of oldcomm 2013-02-01 21:22:49 -08:00
Brian Anderson
65f711a617 rustdoc: Fix some search-and-replace fallout 2013-02-01 21:22:49 -08:00
Brian Anderson
c6e8af446f rustdoc: Remove definitions of spawn_listener and spawn_conversation 2013-02-01 21:22:49 -08:00
Graydon Hoare
89c8ef792f check-fast fallout from removing export, r=burningtree 2013-02-01 19:43:17 -08:00
Daniel Micay
dffc3f82b2 vim: 'fail' is no longer a keyword 2013-02-01 19:32:03 -05:00
bors
b2c01b5892 automated merge 2013-02-01 16:26:35 -08:00
Brian Anderson
04f93be158 Fix breakage 2013-02-01 15:24:16 -08:00
Graydon Hoare
f6c84129b4 README.txt: Mention linenoise 2013-02-01 15:00:12 -08:00
Daniel Micay
6052d67474 vim: pub is just a plain old token keyword 2013-02-01 14:21:32 -05:00
Daniel Micay
00201c969d vim: use StorageClass for mut and const 2013-02-01 14:21:32 -05:00
Daniel Micay
1c3cca8a57 vim: 'be' is a reserved keyword 2013-02-01 14:21:32 -05:00
Daniel Micay
5b47c551b9 vim: unsafe:: namespaces were renamed to raw:: 2013-02-01 14:21:32 -05:00
Daniel Micay
405b868ae7 vim: add Self type 2013-02-01 14:21:25 -05:00
Brian Anderson
9dc6938292 Merge remote-tracking branch 'nickdesaulniers/issue4524' into nocomm1 2013-02-01 11:18:58 -08:00
Brian Anderson
a05bbb2013 Merge pull request #4720 from jbclements/syntactic-cleanup
Syntactic cleanup
2013-02-01 11:18:21 -08:00
Daniel Micay
0c1a345d01 vim: export is no longer a keyword 2013-02-01 13:20:03 -05:00
Brian Anderson
959e382377 Revert "DO NOT COMMIT"
This reverts commit 76679c1f91.
2013-02-01 00:17:56 -08:00
Brian Anderson
e30388f682 Long lines 2013-02-01 00:17:07 -08:00
Brian Anderson
c1a1722ca1 rustdoc: Convert page_pass to pipes 2013-02-01 00:16:14 -08:00
Nick Desaulniers
7868b6bf55 Remove fail keyword from lexer & parser and clean up remaining calls to
fail

Fix merge conflicts - Issue 4524
2013-02-01 00:15:42 -08:00
Brian Anderson
76679c1f91 DO NOT COMMIT 2013-02-01 00:00:17 -08:00
Brian Anderson
63c16e9e79 rustdoc: Convert astsrv to pipes 2013-02-01 00:00:17 -08:00
John Clements
a2839246be cleanup for make check 2013-01-31 23:05:12 -08:00
John Clements
4af7c643f2 more cleanup 2013-01-31 23:05:12 -08:00
John Clements
53688addaa test cases, cleanup 2013-01-31 23:05:12 -08:00
Nick Desaulniers
6fb4239bb3 Replace most invocations of fail keyword with die! macro 2013-01-31 22:25:12 -08:00
Daniel Micay
74b317ddc2 modernize smallintmap
* switch to explicit self
* get rid of the @ box
* replace DVec with ~[] (to get rid of the mutable field)
* implement the new container::Map trait
2013-01-31 23:22:51 -05:00
Daniel Micay
348d770fed copy oldsmallintmap.rs to smallintmap.rs 2013-01-31 23:13:56 -05:00
Daniel Micay
70855f5a07 move smallintmap to oldsmallintmap 2013-01-31 23:13:56 -05:00
Daniel Micay
9ba7114515 implement container::Mutable for SmallIntMap 2013-01-31 23:13:56 -05:00
Daniel Micay
aac91267e3 clean up SmallIntMap tests a bit 2013-01-31 23:13:56 -05:00
Daniel Micay
1057eea7ac drop the StdMap implementation from SmallIntMap 2013-01-31 23:13:55 -05:00
Daniel Micay
274e75cd82 implement container::Container for SmallIntMap 2013-01-31 23:13:55 -05:00
Nick Desaulniers
aee7929469 Replace most invocations of fail keyword with die! macro 2013-01-31 20:12:49 -08:00
Tim Chevalier
2db3175c76 rustc: Stamp out XXXes in middle (comments only) 2013-01-31 19:48:43 -08:00
Tim Chevalier
6f0bede97c testsuite: Remove call to set_buffer_, use set_buffer 2013-01-31 19:35:57 -08:00
Tim Chevalier
e6e1470f97 syntax: remove transitional code 2013-01-31 19:35:57 -08:00
Tim Chevalier
793f20ad32 std: remove transitional code 2013-01-31 19:35:57 -08:00
Tim Chevalier
a9587b8fcd core: Remove transitional code 2013-01-31 19:35:57 -08:00
Tim Chevalier
a71d004393 Don't generate set_buffer 2013-01-31 19:35:56 -08:00
Tim Chevalier
845b06542e messing around with pipes and stages 2013-01-31 19:35:56 -08:00
Tim Chevalier
e0281d991c core: Stamp out XXXes (comments only) 2013-01-31 19:34:46 -08:00
Brian Anderson
5aacf791e8 Merge pull request #4706 from sanxiyn/cleanup-fixme
Cleanup FIXMEs (#3488)
2013-01-31 17:00:27 -08:00
Brian Anderson
9673005afe Merge pull request #4703 from sanxiyn/remove-tps
Remove `tps` from `trans_enum_def` and `trans_struct_def`
2013-01-31 16:59:47 -08:00
Brian Anderson
c95c7c87b1 Merge pull request #4702 from aydinkim/patch-1
Delete unnecessary logs
2013-01-31 16:57:30 -08:00
Niko Matsakis
71478f9ce3 Workaround for #4717: pad contents of ast. rs=breakage 2013-01-31 16:56:12 -08:00
Niko Matsakis
0682ad0eb9 Finalize moves-based-on-type implementation.
Changes:

- Refactor move mode computation
- Removes move mode arguments, unary move, capture clauses
  (though they still parse for backwards compatibility)
- Simplify how moves are handled in trans
- Fix a number of illegal copies that cropped up
- Workaround for bug involving def-ids in params
  (see details below)

Future work (I'll open bugs for these...):

- Improve error messages for moves that are due
  to bindings
- Add support for moving owned content like a.b.c
  to borrow check, test in trans (but I think it'll
  "just work")
- Proper fix for def-ids in params

Def ids in params:

Move captures into a map instead of recomputing.

This is a workaround for a larger bug having to do with the def-ids associated
with ty_params, which are not always properly preserved when inlining.  I am
not sure of my preferred fix for the larger bug yet.  This current fix removes
the only code in trans that I know of which relies on ty_param def-ids, but
feels fragile.
2013-01-31 12:09:00 -08:00
Seo Sanghyeon
7b268e8316 Cleanup FIXMEs (#3488) 2013-01-31 19:23:18 +09:00
Seo Sanghyeon
0d1058a62e Remove tps from trans_enum_def and trans_struct_def 2013-01-31 17:12:33 +09:00
Aydin Kim
6102d2abf2 Delete unnecessary logs 2013-01-31 15:47:44 +09:00
Patrick Walton
42b462e076 test: Attempt to fix Windows check-fast resolve bustage. rs=bustage 2013-01-30 21:57:23 -08:00
Patrick Walton
767d2c0a97 test: De-export sudoku. rs=burningtree 2013-01-30 21:46:47 -08:00
Ben Striegel
9330b2f7b9 Fix bench/sudoku, broken by deëxporting 2013-01-31 00:06:48 -05:00
Ben Striegel
b5f61fddde Repair RIMOV damage to benchmarks 2013-01-30 23:21:57 -05:00
Ben Striegel
df04bd6c6c Revert RIMOV to compile-fail tests 2013-01-30 23:21:57 -05:00
Ben Striegel
3e2ed18a4c RIMOV: fix issue-3563-3 test 2013-01-30 23:21:57 -05:00
Ben Striegel
bb642350e1 Repair RIMOV damage to run-pass 2013-01-30 23:21:57 -05:00
Ben Striegel
df36bfa758 Repair RIMOV damage to libstd tests 2013-01-30 23:21:57 -05:00
Ben Striegel
155f81d4a3 Revert RIMOV on librustc 2013-01-30 23:21:57 -05:00
Ben Striegel
13076eb3b0 Fix RIMOV damage to libsyntax 2013-01-30 23:21:16 -05:00
Ben Striegel
dafd759b20 Repair RIMOV damage to libstd 2013-01-30 23:21:16 -05:00
Ben Striegel
5e55fe8758 Revert RIMOV for libcore 2013-01-30 23:21:16 -05:00
Ben Striegel
cc3bb7b68a What, no syntax for mutable borrowed region pointers? 2013-01-30 23:20:32 -05:00
Ben Striegel
743c1c37e8 RIMOV, round 11
Last bit of mut removal, manually cleaning up outliers
2013-01-30 23:19:40 -05:00
Ben Striegel
0336a8633f RIMOV, round 10
find ./ -type f -name "*.rs" -exec sed -i "s/~\[mut /~\[/g" {} \;
2013-01-30 23:19:08 -05:00
Ben Striegel
3e95a13577 RIMOV, round 8
find ./ -type f -name "*.rs" -exec sed -i "s/  \([a-zA-Z_]\+\): ~\[mut /
mut \1: ~\[/g" {} \;
2013-01-30 23:19:08 -05:00
Ben Striegel
b4f47eca2a RIMOV, round 7
find ./ -type f -name "*.rs" -exec sed -i "s/ mut \([a-zA-Z_]\+\):
~\[mut / mut \1: ~\[/g" {} \;
2013-01-30 23:18:08 -05:00
Ben Striegel
1c9b5a83b2 RIMOV, round 6.
This gets rid of `mut` inside bare vectors. It's going to cause some
problems later.
2013-01-30 23:18:08 -05:00
Ben Striegel
610fd6bc93 Remove two FIXMEs from the long-dead issue 3226 2013-01-30 23:18:08 -05:00
Ben Striegel
f08af9a7a5 RIMOV, round 5
find ./ -type f -name "*.rs" -exec sed -i "s/\&\[mut /\&mut \[/g" {} \;
2013-01-30 23:18:08 -05:00
Ben Striegel
12e8151fb0 RIMOV, round 4
find ./ -type f -name "*.rs" -exec sed -i "s/let mut \(.*\)\[mut[
]\?/let mut \1\[/g" {} \;
2013-01-30 23:16:56 -05:00
Ben Striegel
5577ce635f RIMOV, round 3
find ./ -type f -name "*.rs" -exec sed -i "s/let \(.*\)\[mut[ ]\?/let
mut \1\[/g" {} \;
2013-01-30 23:16:56 -05:00
Ben Striegel
097c8aefea RIMOV, round 2
Running the same command, again:

find ./ -type f -name "*.rs" -exec sed -i "s/let mut\(.*\)\[mut[ ]\?/let
mut\1\[/g" {} \;
2013-01-30 23:16:56 -05:00
Ben Striegel
a8ff91a630 Removing interior mut on vectors, round 1
find ./ -type f -name "*.rs" -exec sed -i "s/let mut\(.*\)\[mut[ ]\?/let
mut\1\[/g" {} \;
2013-01-30 23:16:56 -05:00
Brian Anderson
7d8ae4403e rustdoc: deny(deprecated_self) 2013-01-30 19:56:37 -08:00
Patrick Walton
366812a5c3 librustc: Change self as a type to Self everywhere. r=brson 2013-01-30 19:52:45 -08:00
Brian Anderson
63b2b9c4a8 rustdoc: Remove structural records 2013-01-30 19:45:39 -08:00
Brian Anderson
baf301cd3e rustdoc: De-mode 2013-01-30 19:32:36 -08:00
Brian Anderson
16ea4b06ab rustdoc: Stop using a custom error handler. Closes #4698 2013-01-30 19:02:31 -08:00
Brian Anderson
409d8af3c4 rustdoc: deny(deprecated_mode) 2013-01-30 18:52:31 -08:00
Brian Anderson
1ee94529d9 rustdoc: Various bits of modernization 2013-01-30 18:20:45 -08:00
Patrick Walton
49472ec4c9 librustc: Remove legacy exports from the language. r=brson 2013-01-30 18:11:43 -08:00
Graydon Hoare
040035cd08 test: fix compile-fail tests somehow missed from local 'make check', r=burningtree. 2013-01-30 17:07:35 -08:00
Graydon Hoare
4030aaff20 rustc: make integral type inference transactional, close #3211, close #4401, close #3398. 2013-01-30 16:21:19 -08:00
Patrick Walton
592c2e1db4 test: Remove export from the tests, language, and libraries. rs=deexporting 2013-01-30 15:56:40 -08:00
Patrick Walton
2a65842c3a test: De-export aux, bench, compile-fail, and run-fail. rs=deexporting 2013-01-30 15:08:45 -08:00
Tim Chevalier
77f2aac389 Merge pull request #4687 from alexcrichton/hashmap-speedup
Use task local random when initializing LinearMap
2013-01-30 14:48:49 -08:00
Tim Chevalier
3e9c95e1f7 Merge pull request #4690 from codeblack08/test-round
Add test for float::round
2013-01-30 14:40:50 -08:00
Patrick Walton
d2e1bfb123 librustc: Long line. rs=burning 2013-01-30 14:30:42 -08:00
Patrick Walton
83ced67d0b librustdoc: De-export compiletest, combine-tests, libcargo, libfuzzer, and librustdoc. rs=deexporting 2013-01-30 14:30:42 -08:00
Tim Chevalier
d73bf62952 testsuite: Add xfailed test for #4542 2013-01-30 14:07:08 -08:00
Tim Chevalier
d5c6d94e7e Test case 2013-01-30 14:06:16 -08:00
Patrick Walton
ae50912875 librustc: De-export rustc. rs=deexporting 2013-01-30 13:44:24 -08:00
Patrick Walton
cc9999c609 librustc: De-record the type context. rs=derecordification 2013-01-30 13:14:58 -08:00
Patrick Walton
684aa2b7fd librustc: De-export ty. rs=deexporting 2013-01-30 12:18:08 -08:00
Patrick Walton
ba11e96289 librustc: De-export trans. rs=deexporting 2013-01-30 11:47:02 -08:00
Brian Anderson
7ad0716275 rustc: Convert to pipes 2013-01-30 01:52:01 -08:00
Cody Schroeder
b505504dc4 Add test for float::round 2013-01-30 01:28:04 -08:00
Brian Anderson
02e907b648 Remove oldcomm from the test suite 2013-01-30 00:48:10 -08:00
Alex Crichton
c75e59ac0f Use task local random when initializing maps 2013-01-30 02:49:58 -05:00
Patrick Walton
28ed9dc09e librustc: Long lines. rs=burning 2013-01-29 22:40:13 -08:00
Patrick Walton
0c1d9befb3 librustc: Speed up byte copy operations. r=nmatsakis 2013-01-29 22:15:06 -08:00
Patrick Walton
97c593a1ce librustc: Stop zeroing out allocas so much. Cuts 300K off librustc. 2013-01-29 22:14:08 -08:00
Patrick Walton
1b613ff9fc librustc: Strdup unique strings instead of copying in byte by byte. Shaves 2MB off librustc at -O0. 2013-01-29 22:14:08 -08:00
Patrick Walton
a47fa9b32f librustc: De-export some of trans. rs=deexporting 2013-01-29 22:14:08 -08:00
Tim Chevalier
4b8dfad5cd core tests: Add use vec; directive inside core::hashmap tests
This is probably to work around a bug.
2013-01-29 20:43:44 -08:00
Tim Chevalier
90cee95e51 xfail transitive inheritance test -- I guess this doesn't work yet 2013-01-29 20:33:22 -08:00
Tim Chevalier
a30ea013f5 Handle supertrait calls in default methods
Add a new method_super origin for supertrait methods. Also make
coherence create a table that maps pairs of trait IDs and self types
to impl IDs, so that it's possible to check a supertrait method
knowing only its index in its trait's methods (without knowing all
supertraits for a given trait).

r=nmatsakis and graydon -- with hope, we'll revamp all of this code as
per #4678, but for now this fixes the bug.

Closes #3979
2013-01-29 20:33:22 -08:00
Tim Chevalier
b927e48a26 Merge pull request #4682 from thestinger/treemap
Set trait improvements + minor treemap cleanup
2013-01-29 20:09:15 -08:00
Brian Anderson
da4b376897 std: Stop using oldcomm 2013-01-29 19:54:55 -08:00
Tim Chevalier
87acde8826 rustdoc: Remove structural records from tests. Fixes build breakage 2013-01-29 19:49:47 -08:00
Tim Chevalier
0aef28dd6d De-capitalize "note" to get rid of spurious tidy warnings 2013-01-29 19:26:55 -08:00
Daniel Micay
6b08683e15 add intersection and union to the Set trait 2013-01-29 22:24:00 -05:00
Daniel Micay
99eb4ddddd add difference and symmetric_difference to Set 2013-01-29 21:59:58 -05:00
Daniel Micay
42cafcee2c add is_disjoint to the Set trait 2013-01-29 21:30:55 -05:00
Daniel Micay
bfa9c9a00f add is_subset and is_superset to the Set trait 2013-01-29 21:30:55 -05:00
Daniel Micay
456af7a79d update comments documenting issue #4492 workaround 2013-01-29 21:30:55 -05:00
Daniel Micay
a388e2c1a4 treemap: rm a bit of redundant code 2013-01-29 21:30:55 -05:00
Patrick Walton
464ec27fd3 librustc: De-export metadata. rs=deexporting 2013-01-29 16:51:16 -08:00
Patrick Walton
bae4821851 librustc: De-export typeck. rs=deexporting 2013-01-29 16:26:16 -08:00
Patrick Walton
c25703ccb8 librustc: De-export front, borrowck, and typeck/check. rs=deexporting 2013-01-29 16:05:13 -08:00
Patrick Walton
2ea2628ca9 librustc: De-export back, lib, and util. rs=deexporting 2013-01-29 15:48:50 -08:00
Patrick Walton
3105bcfdc1 librustc: De-export driver. rs=deexport 2013-01-29 15:16:43 -08:00
Patrick Walton
b070590564 libsyntax: De-export libsyntax. rs=deexporting 2013-01-29 14:42:23 -08:00
Tim Chevalier
a80a65b3b7 Merge pull request #4676 from thestinger/fuzzy
fix FuzzyEq
2013-01-29 13:58:39 -08:00
Patrick Walton
95b892c8a7 libsyntax: De-export a lot of libsyntax. rs=deëxporting 2013-01-29 13:55:30 -08:00
Daniel Micay
1aa9fdff56 fix FuzzyEq 2013-01-29 16:54:55 -05:00
Tim Chevalier
66b07f1e5d Fix licenseck to allow 2012-2013 as the year range 2013-01-29 13:48:40 -08:00
Tim Chevalier
7bc919909a testsuite: Xfail file that I added by mistake 2013-01-29 13:42:21 -08:00
Tim Chevalier
5e77d55326 Merge pull request #4664 from thestinger/fuzzy
FuzzyEq improvements
2013-01-29 13:36:43 -08:00
Daniel Micay
e0728d41f2 implement fuzzy_eq with fuzzy_eq_eps 2013-01-29 15:35:26 -05:00
Patrick Walton
f1ddb2a32c libstd: De-export libstd. rs=deexport 2013-01-29 12:06:09 -08:00
Patrick Walton
d0391c5b09 libcore: De-export libcore. rs=deexporting 2013-01-29 11:48:46 -08:00
Patrick Walton
4ead38bae7 libsyntax: Implement the impl Trait for Type syntax 2013-01-29 11:48:21 -08:00
Tim Chevalier
1b021d5868 Long line 2013-01-29 11:44:46 -08:00
Tim Chevalier
8cb17ad0fa Merge pull request #4668 from ILyoan/i2673
fix #2673: avoid visiting the same crate twice
2013-01-29 10:54:44 -08:00
Patrick Walton
226cd68f13 librustc: De-implicit-self the visitor. r=graydon 2013-01-29 10:43:12 -08:00
Patrick Walton
6ce74460e6 librustc: Disallow trait bounds in types, enumerations, and structure definitions. r=tjc 2013-01-29 10:42:58 -08:00
Patrick Walton
eb4d39e1fe libstd: Remove "dual impls" from the language and enforce coherence rules. r=brson
"Dual impls" are impls that are both type implementations and trait
implementations. They can lead to ambiguity and so this patch removes them
from the language.

This also enforces coherence rules. Without this patch, records can implement
traits not defined in the current crate. This patch fixes this, and updates
all of rustc to adhere to the new enforcement. Most of this patch is fixing
rustc to obey the coherence rules, which involves converting a bunch of records
to structs.
2013-01-29 10:42:45 -08:00
Alex Crichton
810eeef444 Fix the len() method on LinearMap during popping 2013-01-29 11:16:39 -05:00
ILyoan
8ec36d779b fix #2673: avoid visiting the same crate twice 2013-01-29 21:03:05 +09:00
Tim Chevalier
fc9650b146 testsuite: De-record most bench tests 2013-01-28 19:41:56 -08:00
Tim Chevalier
3b36708ca7 testsuite: De-record pretty tests 2013-01-28 19:41:56 -08:00
Tim Chevalier
58ec84a098 testsuite: Remove structural records from remaining compile-fail tests 2013-01-28 19:41:56 -08:00
Tim Chevalier
15871a7458 rustc: Check struct field types when heap memory lint checks are enabled 2013-01-28 19:41:56 -08:00
Tim Chevalier
91676f3fa6 syntax: Don't add an extra space before the last comma...
...when printing struct update expressions.
2013-01-28 19:41:56 -08:00
Tim Chevalier
9f11485357 testsuite: Allow structural records in two tests that use pipes 2013-01-28 19:41:56 -08:00
Tim Chevalier
93043baab4 testsuite: Add #[allow(structural_records)] to pipes tests
These will require a snapshot.
2013-01-28 19:41:56 -08:00
Tim Chevalier
dd38af240b compiletest: Allow legacy records
But also remove most uses of structural records.
2013-01-28 19:41:56 -08:00
Tim Chevalier
c5461e46ae core: Allow legacy records in in a few modules
Because of macros, #[allow(structural_records]] in
extfmt, gc, os, pipes, and run. Will need a snapshot.
2013-01-28 19:41:56 -08:00
Tim Chevalier
31d78b2f07 Add #[legacy_records] crate attribute
In rustc, rustdoc, rusti, syntax, and std.
2013-01-28 19:41:56 -08:00
Tim Chevalier
6cbccc92b7 rustc: In lint, forbid structural records unless legacy_records is on 2013-01-28 19:41:55 -08:00
Tim Chevalier
db6af50d53 rustc: Add legacy_records field to the type context 2013-01-28 19:41:55 -08:00
Brian Anderson
a72aeef9f7 Revert readline optimization and add test 2013-01-28 19:32:02 -08:00
Daniel Micay
fce6446e7e add a FuzzyEq method that accepts an epsilon value 2013-01-28 21:25:58 -05:00
Tim Chevalier
3a6849f36b Revert "Revert "Merge pull request #4633 from thestinger/treemap""
This reverts commit d73077f82d.
2013-01-28 17:20:29 -08:00
Daniel Micay
abb79cb52d update FuzzyEq to explicit self 2013-01-28 19:28:40 -05:00
Daniel Micay
52975202af fix std::cmp docstring 2013-01-28 19:28:23 -05:00
Brian Anderson
d9170e14b1 Tidy 2013-01-28 14:41:20 -08:00
Michael Neumann
d38939c7e8 Slightly optimize read_line()
No need to allocate an additional vector. Instead directly push into the
string.
2013-01-28 14:40:11 -08:00
Michael Neumann
1ecdf3abc1 Greatly improve performance for TcpSocketBuf.read
For every call to the read() function the internal buffer was copied
into a new buffer (minus the bytes copied into the result buffer). When
the internal buffer is large enough, this severely affects performance,
especially when read_line() is used which calls read_byte() (which calls
read()) for each read byte.

For line oriented I/O this wasn't all that bad, because the internal
buffers usually never were very big. The effect is much more visible
once the buffer grows larger.

Now we always first look into the internal buffer and copy as many bytes
as possible (and desired) into the result buffer. If we need more, we
call the socket read function and use the result as the new internal
buffer, then continue to copy from the (new) internal buffer, and so on.
2013-01-28 14:40:11 -08:00
Michael Neumann
0c3ef3cc6b Convert log(debug, ...) to debug!(...) 2013-01-28 14:40:11 -08:00
Michael Neumann
02de11c1e7 Fix example code 2013-01-28 14:40:11 -08:00
Brian Anderson
2a48aef0a8 Merge remote-tracking branch 'thestinger/hashmap' into deriving 2013-01-28 14:28:59 -08:00
Brian Anderson
c75cc0aa10 Merge remote-tracking branch 'codeblack08/treemap-ord' into deriving 2013-01-28 14:15:58 -08:00
Daniel Micay
8eaf0737b7 get rid of LinearMap's find_copy method 2013-01-28 16:06:09 -05:00
Niko Matsakis
e8f3690123 Change "// WARN" in tidy to "// NOTE" as requested by @catamorphism 2013-01-28 10:01:59 -08:00
Niko Matsakis
ef4c060594 Address @catamorphism's comments regarding docs 2013-01-28 10:01:59 -08:00
Niko Matsakis
4b15bfde81 loan: Track whether or not the current path owns the data being
lent.  We can be more liberal with respect to the scope of the loan
if we do not own the data being lent, which used to be impossible
but can now occur with `&mut`.

r=pcwalton
2013-01-28 10:01:59 -08:00
Niko Matsakis
b4acde3bf7 remove unused variable 2013-01-28 10:01:59 -08:00
Niko Matsakis
e6cadc4c03 remove hacks now that #3148 is fixed
r=brson
2013-01-28 10:01:59 -08:00
Niko Matsakis
2b67d88809 Rewrite the coercion code to be more readable, more sound, and to reborrow when
needed.

Regarding soundness: there was a subtle bug in how it was done before; see the
compile-fail test for an example.

Regarding reborrowing: reborrowing allows mut and const
slices/borrowed-pointers to be used with pure fns that expect immutable data.

r=brson
2013-01-28 10:01:59 -08:00
Niko Matsakis
c07ae16de1 rename assign to coerce, remove some bad copies
r=brson
2013-01-28 10:01:59 -08:00
Niko Matsakis
05b6df49b8 Refactor to make inference code around unification more readable
r=brson
2013-01-28 10:01:59 -08:00
Niko Matsakis
923b3154c6 Do not try to encode/decode inference types, should not be necessary
r=brson
2013-01-28 10:01:59 -08:00
Niko Matsakis
19e015c44a Add to_str() definitions for some AST types
r=brson
2013-01-28 10:01:59 -08:00
Niko Matsakis
08bc19cbcd Remove bounds from type decl of smallintmap
r=brson
2013-01-28 10:01:55 -08:00
Niko Matsakis
a4ba11189d Extend region guarantor logic to handle autoref, which will
be necessary for reborrowing.

r=catamorphism
2013-01-28 10:00:41 -08:00
Niko Matsakis
8f14d43206 Make tidy actually work
r=catamorphism
2013-01-28 10:00:39 -08:00
Niko Matsakis
0004be9eca Detect "// WARN" in tidy and print out, well, a warning! Useful
for notating FIXME-style-situations that you want to be reminded
of before you commit.

r=catamorphism
2013-01-28 10:00:35 -08:00
Niko Matsakis
2e10ea58c3 Integrate vec patterns into borrow checker.
The tail portion of the pattern effectively borrows a vector,
but the borrow checker knew nothing about this.

r=catamorphism
2013-01-28 10:00:32 -08:00
Niko Matsakis
d4fd30c6ac Link the lifetimes of regions resulting from borrows of the
contents of other borrowed pointers to the lifetimes of the
borrowed value.  Fixes #3148.

r=catamorphism
2013-01-28 10:00:23 -08:00
Cody Schroeder
6a4d1855bf std: implement lexicographical Ord for TreeMap/TreeSet 2013-01-26 16:39:17 -08:00
Brian Anderson
83ca034d2e Merge remote-tracking branch 'brson/nocommupstream2' 2013-01-26 14:57:58 -08:00
Graydon Hoare
2372d2c6a8 register more-conservative linux snap 2013-01-26 14:11:34 -08:00
Tim Chevalier
bb183b93ea testsuite: Eliminate structural records from run-fail tests 2013-01-26 11:38:00 -08:00
Tim Chevalier
72b669df43 fuzzer: Remove structural records 2013-01-26 11:35:17 -08:00
Tim Chevalier
e910e601a6 cargo: remove structural records 2013-01-26 11:35:17 -08:00
Tim Chevalier
0743cec023 core: Remove structural records in library tests 2013-01-26 11:35:17 -08:00