Skip to content

Commit

Permalink
Merge pull request rust-lang#1 from nikomatsakis/dk-broken-branch
Browse files Browse the repository at this point in the history
Dk broken branch
  • Loading branch information
atris committed Sep 27, 2012
2 parents 692aea1 + e4077dc commit f38ca0b
Show file tree
Hide file tree
Showing 943 changed files with 21,320 additions and 18,125 deletions.
4 changes: 4 additions & 0 deletions AUTHORS.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ Benjamin Jackman <ben@jackman.biz>
Benjamin Kircher <benjamin.kircher@gmail.com>
Brendan Eich <brendan@mozilla.org>
Brian Anderson <banderson@mozilla.com>
Brian J. Burg <burg@cs.washington.edu>
Chris Double <chris.double@double.co.nz>
Chris Peterson <cpeterson@mozilla.com>
Damian Gryski <damian@gryski.com>
Expand All @@ -29,6 +30,8 @@ Daniel Patterson <dbp@riseup.net>
Dave Herman <dherman@mozilla.com>
David Rajchenbach-Teller <dteller@mozilla.com>
Donovan Preston <donovanpreston@gmail.com>
Drew Willcoxon <adw@mozilla.com>
Elliott Slaughter <elliottslaughter@gmail.com>
Elly Fong-Jones <elly@leptoquark.net>
Eric Holk <eric.holk@gmail.com>
Erick Tryzelaar <erick.tryzelaar@gmail.com>
Expand Down Expand Up @@ -77,6 +80,7 @@ Patrick Walton <pwalton@mozilla.com>
Patrik Kårlin <patrik.karlin@gmail.com>
Paul Stansifer <paul.stansifer@gmail.com>
Peter Hull <peterhull90@gmail.com>
Philipp Brüschweiler <blei42@gmail.com>
Rafael Ávila de Espíndola <respindola@mozilla.com>
Ralph Giles <giles@thaumas.net>
Reuben Morais <reuben.morais@gmail.com>
Expand Down
15 changes: 13 additions & 2 deletions Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -355,18 +355,29 @@ endif
# Add RUSTFLAGS_STAGEN values to the build command
EXTRAFLAGS_STAGE$(1) = $$(RUSTFLAGS_STAGE$(1))

CFGFLAG$(1)_T_$(2)_H_$(3) = stage$(1)

# Pass --cfg stage0 only for the build->host part of stage0;
# if you're building a cross config, the host->* parts are
# effectively stage1, since it uses the just-built stage0.
ifeq ($(1),0)
ifneq ($(strip $(CFG_HOST_TRIPLE)),$(strip $(3)))
CFGFLAG$(1)_T_$(2)_H_$(3) = stage1
endif
endif

STAGE$(1)_T_$(2)_H_$(3) := \
$$(Q)$$(call CFG_RUN_TARG,$(1), \
$$(CFG_VALGRIND_COMPILE$(1)) \
$$(HBIN$(1)_H_$(3))/rustc$$(X) \
--cfg stage$(1) \
--cfg $$(CFGFLAG$(1)_T_$(2)_H_$(3)) \
$$(CFG_RUSTC_FLAGS) $$(EXTRAFLAGS_STAGE$(1)) --target=$(2))

PERF_STAGE$(1)_T_$(2)_H_$(3) := \
$$(Q)$$(call CFG_RUN_TARG,$(1), \
$$(CFG_PERF_TOOL) \
$$(HBIN$(1)_H_$(3))/rustc$$(X) \
--cfg stage$(1) \
--cfg $$(CFGFLAG$(1)_T_$(2)_H_$(3)) \
$$(CFG_RUSTC_FLAGS) $$(EXTRAFLAGS_STAGE$(1)) --target=$(2))

endef
Expand Down
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ an earlier state of development). As such, source builds require that:

* Windows (7, server 2008 r2) x86 only
* Linux 2.6.x (various distributions) x86 and x86-64
* OSX 10.6 ("Snow leopard") or 10.7 ("Lion") x86 and x86-64
* OSX 10.6 ("Snow Leopard") or 10.7 ("Lion") x86 and x86-64

You may find other platforms work, but these are our "tier 1" supported build
environments that are most likely to work. Further platforms will be added to
Expand All @@ -34,8 +34,8 @@ To build from source you will also need the following prerequisite packages:
Assuming you're on a relatively modern Linux/OSX system and have met the
prerequisites, something along these lines should work:

$ tar -xzf rust-0.3.tar.gz
$ cd rust-0.3
$ tar -xzf rust-0.4.tar.gz
$ cd rust-0.4
$ ./configure
$ make && make install

Expand All @@ -59,10 +59,10 @@ information on them.
Rust is primarily distributed under the terms of the MIT license, with
portions covered by various BSD-like licenses.

See LICENSE.txt for complete terms of copyright and redistribution.

See LICENSE.txt for details.

## More help

The [tutorial](http://dl.rust-lang.org/doc/tutorial.html) is a good
starting point.
The [tutorial] is a good starting point.

[tutorial]: http://dl.rust-lang.org/doc/tutorial.html
57 changes: 57 additions & 0 deletions RELEASES.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,60 @@
Version 0.4 (September 2012)
----------------------------

* ~1500 changes, numerous bugfixes

* Syntax
* All keywords are now strict and may not be used as identifiers anywhere
* Keyword removal: 'again', 'import', 'check', 'new', 'owned', 'send',
'of', 'with', 'to', 'class'.
* Classes are replaced with simpler structs
* Method self types
* `ret` became `return` and `alt` became `match`
* `import` is now `use`; `use is now `extern mod`
* `extern mod { ... }` is now `extern { ... }`
* `use mod` is the recommended way to import modules
* `pub` and `priv` replace deprecated export lists
* The syntax of `match` pattern arms now uses fat arrow (=>)

* Semantics
* Trait implementations are now coherent, ala Haskell typeclasses
* Trait methods may be static
* Argument modes are deprecated
* Borrowed pointers are much more mature and recommended for use
* Strings and vectors in the static region are stored in constant memory
* Typestate was removed
* Resolution rewritten to be more reliable
* Support for 'dual-mode' data structures (freezing and thawing)
* Last-use analysis is only used for warnings now. Moves must be explicit
for lvalues (TODO: confirm)

* Libraries
* Most binary operators can now be overloaded via the traits in
`core::ops'
* `std::net::url` for representing URLs
* Sendable hash maps in `core::send_map`
* `core::task' gained a (currently very unsafe) task-local storage API

* Concurrency
* An efficient new intertask communication primitive called the pipe,
along with a number of higher-level channel types, in `core::pipes`
* `std::arc`, an atomically reference counted, immutable, shared memory
type
* `std::sync`, various exotic synchronization tools based on arcs and pipes
* Futures are now based on pipes and sendable
* More robust linked task failure
* Improved task builder API

* Other
* Improved error reporting
* Preliminary JIT support
* Preliminary work on precise GC
* Extensive architectural improvements to rustc
* Begun a transition away from buggy C++-based reflection (shape) code to
Rust-based (visitor) code
* Hash functions improved across the codebase (TODO: need details)
* New lint checks (TODO: which?)

Version 0.3 (July 2012)
------------------------

Expand Down
6 changes: 5 additions & 1 deletion configure
Original file line number Diff line number Diff line change
Expand Up @@ -400,7 +400,7 @@ then
| cut -d ' ' -f 2)

case $CFG_CLANG_VERSION in
(3.0svn | 3.0 | 3.1 | 4.0)
(3.0svn | 3.0 | 3.1 | 4.0 | 4.1)
step_msg "found ok version of CLANG: $CFG_CLANG_VERSION"
CFG_C_COMPILER="clang"
;;
Expand Down Expand Up @@ -505,6 +505,10 @@ do
make_dir $h/test/perf
make_dir $h/test/pretty
make_dir $h/test/doc-tutorial
make_dir $h/test/doc-tutorial-ffi
make_dir $h/test/doc-tutorial-macros
make_dir $h/test/doc-tutorial-borrowed-ptr
make_dir $h/test/doc-tutorial-tasks
make_dir $h/test/doc-ref
done

Expand Down
18 changes: 9 additions & 9 deletions doc/lib/codemirror-rust.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@ CodeMirror.defineMode("rust", function() {
var indentUnit = 4, altIndentUnit = 2;
var valKeywords = {
"if": "if-style", "while": "if-style", "loop": "if-style", "else": "else-style",
"do": "else-style", "ret": "else-style", "fail": "else-style",
"do": "else-style", "return": "else-style", "fail": "else-style",
"break": "atom", "cont": "atom", "const": "let", "resource": "fn",
"let": "let", "fn": "fn", "for": "for", "alt": "alt", "trait": "trait",
"impl": "impl", "type": "type", "enum": "enum", "class": "atom", "mod": "mod",
"let": "let", "fn": "fn", "for": "for", "match": "match", "trait": "trait",
"impl": "impl", "type": "type", "enum": "enum", "struct": "atom", "mod": "mod",
"as": "op", "true": "atom", "false": "atom", "assert": "op", "check": "op",
"claim": "op", "extern": "ignore", "unsafe": "ignore", "import": "else-style",
"export": "else-style", "copy": "op", "log": "op", "log_err": "op",
"use": "op", "bind": "op", "self": "atom", "new": "atom"
"export": "else-style", "copy": "op", "log": "op",
"use": "op", "self": "atom"
};
var typeKeywords = function() {
var keywords = {"fn": "fn"};
Expand Down Expand Up @@ -197,7 +197,7 @@ CodeMirror.defineMode("rust", function() {
if (type == "if-style") return cont(expression, expression);
if (type == "else-style" || type == "op") return cont(expression);
if (type == "for") return cont(pattern, maybetype, inop, expression, expression);
if (type == "alt") return cont(expression, altbody);
if (type == "match") return cont(expression, altbody);
if (type == "fn") return cont(fndef);
if (type == "macro") return cont(macro);
return cont();
Expand Down Expand Up @@ -346,7 +346,7 @@ CodeMirror.defineMode("rust", function() {
else return pass();
}
function altbody(type) {
if (type == "{") return cont(pushlex("}", "alt"), altblock1, poplex);
if (type == "{") return cont(pushlex("}", "match"), altblock1, poplex);
return pass();
}
function altblock1(type) {
Expand All @@ -357,7 +357,7 @@ CodeMirror.defineMode("rust", function() {
return pass(pattern, altblock2);
}
function altblock2(type) {
if (type == "{") return cont(pushlex("}", "alt"), block, poplex, altblock1);
if (type == "{") return cont(pushlex("}", "match"), block, poplex, altblock1);
else return pass(altblock1);
}

Expand Down Expand Up @@ -422,7 +422,7 @@ CodeMirror.defineMode("rust", function() {
type = lexical.type, closing = firstChar == type;
if (type == "stat") return lexical.indented + indentUnit;
if (lexical.align) return lexical.column + (closing ? 0 : 1);
return lexical.indented + (closing ? 0 : (lexical.info == "alt" ? altIndentUnit : indentUnit));
return lexical.indented + (closing ? 0 : (lexical.info == "match" ? altIndentUnit : indentUnit));
},

electricChars: "{}"
Expand Down
19 changes: 18 additions & 1 deletion doc/rust.css
Original file line number Diff line number Diff line change
Expand Up @@ -81,4 +81,21 @@ blockquote {
border-left: solid 1px silver;
margin: 1em;
padding: 0.5em 1em 0.5em 1em;
}
}

/* Make the table under the tutorial's 'Types' section look nicer */
table {
border-top: 1px solid silver;
border-bottom: 1px solid silver;
padding: 0.8em;
font-size: smaller;
}
/* Also for the benefit of the type table */
td {
padding-right: 1em;
}

/* Only display one level of hierarchy in the TOC */
#TOC ul ul {
display: none;
}
Loading

0 comments on commit f38ca0b

Please sign in to comment.