Commit Graph

15293 Commits

Author SHA1 Message Date
Jeff Olson 1cbbb58d87 build: change libuv to point at joyent's repo and make unpatched build libuv work on mingw 2013-02-10 11:51:05 -08:00
Jeff Olson 73507c1961 std: strip sillyness from debug comment in iotask teardown 2013-02-10 11:51:05 -08:00
Jeff Olson a74296a39f build: ifdef for mingw/non-mingw builds 2013-02-10 11:51:05 -08:00
Jeff Olson 4942fe9c1e build: point libuv at olsonjeffery/libuv, temporarily 2013-02-10 11:51:05 -08:00
Jeff Olson a38b16651f build: tweak rt.mk, as per graydon.. CFLAGS had to stay 2013-02-10 11:51:05 -08:00
Jeff Olson dfcdb6eb72 rt/std: update of libuv API glue for libuv submodule update 2013-02-10 11:51:05 -08:00
Jeff Olson 3a813e29b6 etc: rework of how libuv is integrated into the build
- thanks to work in libuv's upstream, we can call libuv's Makefile directly
with parameters, instead of descending in gyp-uv madness and generating
our own.
2013-02-10 11:51:05 -08:00
bors 0f04df8522 auto merge of #4866 : jld/rust/enum-unitlike, r=graydon
If an enum is isomorphic to unit, there's no need to use any bits to
represent it.  The only obvious reason this wasn't the case was because
the enum could be C-like and have a user-specified discriminant -- but
that value is constant, so it doesn't need to be stored.

This change means that all newtype-like enums have the same size (and
layout) as their underlying type, which might be a useful property to
have, at least in terms of making programs' low-level behavior less
surprising.
2013-02-10 10:24:17 -08:00
Jed Davis 3742b62f64 Omit discriminant from nullary univariant enums.
If an enum is isomorphic to unit, there's no need to use any bits to
represent it.  The only obvious reason this wasn't the case was because
the enum could be C-like and have a user-specified discriminant -- but
that value is constant, so it doesn't need to be stored.

This change means that all newtype-like enums have the same size (and
layout) as their underlying type, which might be a useful property to
have, at least in terms of making programs' low-level behavior less
surprising.
2013-02-09 22:28:43 -08:00
bors 9d7014e55c auto merge of #4861 : sethpink/rust/incoming, r=catamorphism
Fix for issue #4830.
2013-02-09 18:37:02 -08:00
bors 2fc1f41d0d auto merge of #4827 : mcpherrinm/rust/master, r=catamorphism
It seems to me the library needs more work to be done, but having a non-compilable sample program seems like bad news.
2013-02-09 17:28:04 -08:00
bors d6442e97a5 auto merge of #4854 : thestinger/rust/oldmap, r=catamorphism 2013-02-09 15:02:51 -08:00
bors 7fe6b1b6cf auto merge of #4853 : Thiez/rust/incoming, r=catamorphism
A simple fix for issue 2174.
2013-02-09 14:13:59 -08:00
bors 19dfec2aaf auto merge of #4852 : Caseus/rust/issue-4836, r=brson
Simple removal of rust_compare_and_swap_ptr from rt, as per Issue #4836
2013-02-09 11:07:13 -08:00
bors d90abd5879 auto merge of #4848 : nikomatsakis/rust/issue-4821-bad-kind-computation, r=catamorphism
...ear

values to be copied.  Rewrite kind computation so that instead of directly
computing the kind it computes what kinds of values are present in the type,
and then derive kinds based on that. I find this easier to think about.

Fixes #4821.

r? @catamorphism
2013-02-09 10:20:55 -08:00
Seth Pink 8ebdb3d0ab Issue #4830 fix 2013-02-09 23:00:55 +10:00
Daniel Micay 4e6994dbfa librustc/back/rpath.rs: oldmap -> LinearSet 2013-02-08 21:22:54 -05:00
Daniel Micay d30fdbb357 libsyntax/attr.rs: switch from oldmap to LinearSet 2013-02-08 20:57:14 -05:00
Matthew McPherrin 0a062b50f1 Remove trailing whitespace 2013-02-08 20:17:50 -05:00
Daniel Micay 94fd95a4f1 oldmap: rm unneeded unsafe 2013-02-08 19:30:54 -05:00
Daniel Micay 0127828b5b oldmap: separate out the methods that need Copy 2013-02-08 19:20:36 -05:00
Mark Vian e2e474767e rt: remove unused 'rust_compare_and_swap_ptr'. Closes #4836 2013-02-08 18:19:36 -06:00
Daniel Micay a32c5c73ee oldmap: get rid of legacy _ref suffixes 2013-02-08 19:12:51 -05:00
Matthijs Hofstra 8d0c1cb406 Added related FIXME for 3260 2013-02-09 01:01:39 +01:00
Matthijs Hofstra fd98ea8129 Fix for issue 2174
The function that formats and prints the squigly line that hilights
errors counted tabs as spaces, which resulted in incorrect error
messages when tabs were used for indentation. This change compares
the highlight line with the previous line and inserts a tab instead
of a space whenever such a tab exists on the previous line. Note
that error messages will still highlight incorrectly when the
previous line include characters that require more than one utf8
code point, as mentioned in issue 3260.
2013-02-09 00:57:39 +01:00
bors 0c2b4edff5 auto merge of #4847 : nikomatsakis/rust/region-syntax, r=graydon
cc #4846

r? @pcwalton
2013-02-08 14:25:52 -08:00
Matthew McPherrin 46df7985a5 Merge branch 'master' of https://github.com/mozilla/rust 2013-02-08 15:21:46 -05:00
bors f529af0d50 auto merge of #4844 : jld/rust/const-index-fix, r=graydon
Fixes #3169 and uses that to fix const array indexing, which I broke (in a way that doesn't break tests but will greatly confuse users) while trying to fix const enum vectors.
2013-02-08 10:53:16 -08:00
bors ee93fb2ad5 auto merge of #4845 : osaut/rust/master, r=graydon
There was a simple typo on recursive in doc/tutorial-macros.md: s/recusive/recursive.
2013-02-08 08:47:45 -08:00
Niko Matsakis a380df809c Fix subtle error in caching during kind computation that could cause linear
values to be copied.  Rewrite kind computation so that instead of directly
computing the kind it computes what kinds of values are present in the type,
and then derive kinds based on that. I find this easier to think about.

Fixes #4821.
2013-02-08 07:20:39 -08:00
Niko Matsakis 14930fbffe Add and lex LIFETIME tokens
cc #4846
2013-02-08 06:02:35 -08:00
Olivier Saut 4dec0d5192 Typo s/recusive/recursive/ 2013-02-08 11:45:47 +01:00
Jed Davis 9318babf6c Fix const array index limit calculation.
The number of operands of the LLVM node initializing the array
underlying a const vector isn't always the array length -- if the
array is of a sufficiently primitive type and all the elements' values
are known (or something like that), LLVM uses a specialized Constant
subclass that stores the data packed, and thus has no operands.  Oops.

But, because llsize_of now gives us a ConstantInt, we can just fix
mozilla/rust#3169 and this all goes away.
2013-02-08 01:52:55 -08:00
Jed Davis dd7a81d025 Let llsize_of be a ConstantInt 2013-02-08 01:52:47 -08:00
bors dd41f044da auto merge of #4843 : ILyoan/rust/i1531, r=catamorphism
Fix for #1531
2013-02-08 00:10:49 -08:00
bors e5637226d8 auto merge of #4839 : catamorphism/rust/rm-structural-records, r=catamorphism 2013-02-07 23:16:42 -08:00
Tim Chevalier 3b8f1fa2b6 core: Remove structural records from the rest of core, except pipes
That will, sadly, require one more snapshot.
2013-02-07 22:48:57 -08:00
bors 9b4fa844d8 auto merge of #4835 : thestinger/rust/iterator, r=graydon
This adds a `BaseIter` impl to `PriorityQueue`, `TreeMap`, `LinearMap` and `SmallIntMap`, and introduces a `ReverseIter` trait + implementations for `TreeMap`, `TreeSet` and `SmallIntMap`.
2013-02-07 21:37:59 -08:00
ILyoan e7c6735e0d Fixed #1531 2013-02-08 14:11:00 +09:00
Daniel Micay 8c32cd2dc8 fix map tests 2013-02-07 22:58:16 -05:00
bors e8fc4b347d auto merge of #4834 : veddan/rust/zflags, r=graydon
Converted --static, --gc, --jit, -g and --xg to -Z flags.
2013-02-07 19:50:03 -08:00
Daniel Micay 9599cc86f0 implement BaseIter for LinearMap 2013-02-07 22:28:58 -05:00
bors bc1fb62c34 auto merge of #4745 : jld/rust/constenum-bis, r=graydon
There were a bunch of problems with consts where an enum was contained within some other type (vector, tuple, struct, etc.); some of these would cause LLVM assertion failures, and some would silently read from the wrong address.  These changes should fix all of that.

It would be good if someone with access to a win32 host could do the equivalent of `make check-stageN-rpass TESTNAME=enum` on that platform before merging this.
2013-02-07 19:04:44 -08:00
Daniel Micay fe841f3e56 implement ReverseIter for SmallIntMap 2013-02-07 22:04:38 -05:00
Daniel Micay a2f922f282 implement ReverseIter for TreeMap and TreeSet 2013-02-07 22:04:38 -05:00
Daniel Micay 3e0a28c7da add a ReverseIter trait 2013-02-07 22:04:38 -05:00
Daniel Micay 66d5030763 implement BaseIter for SmallIntMap 2013-02-07 22:04:38 -05:00
Daniel Micay e018244777 make Option's map and map_default use a lifetime 2013-02-07 22:04:38 -05:00
Daniel Micay f6e0df6563 implement BaseIter for TreeMap 2013-02-07 22:04:37 -05:00
Daniel Micay 83270d2d79 rm each method from the Map trait
the map types should implement BaseIter instead
2013-02-07 22:04:35 -05:00