Skip to content

Commit d9e73dd

Browse files
committed
---
yaml --- r: 81911 b: refs/heads/master c: 0f9bcaf h: refs/heads/master i: 81909: 9eb844f 81907: 9d2eb6a 81903: d1a2dd3 v: v3
1 parent 3570879 commit d9e73dd

File tree

124 files changed

+7075
-1069
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

124 files changed

+7075
-1069
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
refs/heads/master: fc44a9c7dd7203315a47b307c774d22f89d864be
2+
refs/heads/master: 0f9bcaf7fe0cebf0d1be0e17025c0e3b76e14507
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 6c08cc2db4f98e9f07ae7d50338396c4123c2f0a
55
refs/heads/try: 70152ff55722878cde684ee6462c14c65f2c4729

trunk/.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
*.cpp rust
55
*.h rust
66
*.rs rust
7+
src/etc/pkg/rust-logo.ico binary
78
src/rt/msvc/* -whitespace
89
src/rt/vg/* -whitespace
910
src/rt/linenoise/* -whitespace

trunk/RELEASES.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
Version 0.8 (October 2013)
1+
Version 0.8 (September 2013)
22
--------------------------
33

4-
* ~2100 changes, numerous bugfixes
4+
* ~2200 changes, numerous bugfixes
55

66
* Language
77
* The `for` loop syntax has changed to work with the `Iterator` trait.

trunk/configure

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -684,7 +684,7 @@ do
684684
isaac linenoise sync test \
685685
arch/i386 arch/x86_64 arch/arm arch/mips \
686686
libuv libuv/src/ares libuv/src/eio libuv/src/ev \
687-
jemalloc
687+
jemalloc sundown/src sundown/html
688688
do
689689
make_dir $t/rt/stage$s/$i
690690
done

trunk/mk/rt.mk

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,16 @@ RUNTIME_CXXS_$(1)_$(2) := \
8282
rt/rust_android_dummy.cpp \
8383
rt/rust_test_helpers.cpp
8484

85-
RUNTIME_CS_$(1)_$(2) := rt/linenoise/linenoise.c rt/linenoise/utf8.c
85+
RUNTIME_CS_$(1)_$(2) := rt/linenoise/linenoise.c \
86+
rt/linenoise/utf8.c \
87+
rt/sundown/src/autolink.c \
88+
rt/sundown/src/buffer.c \
89+
rt/sundown/src/stack.c \
90+
rt/sundown/src/markdown.c \
91+
rt/sundown/html/houdini_href_e.c \
92+
rt/sundown/html/houdini_html_e.c \
93+
rt/sundown/html/html_smartypants.c \
94+
rt/sundown/html/html.c
8695

8796
RUNTIME_S_$(1)_$(2) := rt/arch/$$(HOST_$(1))/_context.S \
8897
rt/arch/$$(HOST_$(1))/ccall.S \
@@ -117,6 +126,8 @@ RUNTIME_DEF_$(1)_$(2) := $$(RT_OUTPUT_DIR_$(1))/rustrt$$(CFG_DEF_SUFFIX_$(1))
117126
RUNTIME_INCS_$(1)_$(2) := -I $$(S)src/rt -I $$(S)src/rt/isaac -I $$(S)src/rt/uthash \
118127
-I $$(S)src/rt/arch/$$(HOST_$(1)) \
119128
-I $$(S)src/rt/linenoise \
129+
-I $$(S)src/rt/sundown/src \
130+
-I $$(S)src/rt/sundown/html \
120131
-I $$(S)src/libuv/include
121132
RUNTIME_OBJS_$(1)_$(2) := $$(RUNTIME_CXXS_$(1)_$(2):rt/%.cpp=$$(RT_BUILD_DIR_$(1)_$(2))/%.o) \
122133
$$(RUNTIME_CS_$(1)_$(2):rt/%.c=$$(RT_BUILD_DIR_$(1)_$(2))/%.o) \

trunk/mk/tests.mk

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -227,8 +227,9 @@ ALL_CS := $(wildcard $(S)src/rt/*.cpp \
227227
$(S)src/rt/*/*/*.cpp \
228228
$(S)src/rustllvm/*.cpp)
229229
ALL_CS := $(filter-out $(S)src/rt/miniz.cpp \
230-
$(S)src/rt/linenoise/linenoise.c \
231-
$(S)src/rt/linenoise/utf8.c \
230+
$(wildcard $(S)src/rt/linenoise/*.c) \
231+
$(wildcard $(S)src/rt/sundown/src/*.c) \
232+
$(wildcard $(S)src/rt/sundown/html/*.c) \
232233
,$(ALL_CS))
233234
ALL_HS := $(wildcard $(S)src/rt/*.h \
234235
$(S)src/rt/*/*.h \
@@ -241,6 +242,8 @@ ALL_HS := $(filter-out $(S)src/rt/vg/valgrind.h \
241242
$(S)src/rt/msvc/inttypes.h \
242243
$(S)src/rt/linenoise/linenoise.h \
243244
$(S)src/rt/linenoise/utf8.h \
245+
$(wildcard $(S)src/rt/sundown/src/*.h) \
246+
$(wildcard $(S)src/rt/sundown/html/*.h) \
244247
,$(ALL_HS))
245248

246249
# Run the tidy script in multiple parts to avoid huge 'echo' commands

trunk/src/etc/pkg/rust-logo.ico

2 Bytes
Binary file not shown.

trunk/src/libextra/arc.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
* In this example, a large vector of floats is shared between several tasks.
1818
* With simple pipes, without Arc, a copy would have to be made for each task.
1919
*
20-
* ~~~ {.rust}
20+
* ```rust
2121
* extern mod std;
2222
* use extra::arc;
2323
* let numbers=vec::from_fn(100, |ind| (ind as float)*rand::random());
@@ -34,7 +34,7 @@
3434
* // Work with the local numbers
3535
* }
3636
* }
37-
* ~~~
37+
* ```
3838
*/
3939

4040
#[allow(missing_doc)];
@@ -440,7 +440,7 @@ impl<T:Freeze + Send> RWArc<T> {
440440
*
441441
* # Example
442442
*
443-
* ~~~ {.rust}
443+
* ```rust
444444
* do arc.write_downgrade |mut write_token| {
445445
* do write_token.write_cond |state, condvar| {
446446
* ... exclusive access with mutable state ...
@@ -450,7 +450,7 @@ impl<T:Freeze + Send> RWArc<T> {
450450
* ... shared access with immutable state ...
451451
* }
452452
* }
453-
* ~~~
453+
* ```
454454
*/
455455
pub fn write_downgrade<U>(&self, blk: &fn(v: RWWriteMode<T>) -> U) -> U {
456456
unsafe {

trunk/src/libextra/base64.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -62,15 +62,15 @@ impl<'self> ToBase64 for &'self [u8] {
6262
*
6363
* # Example
6464
*
65-
* ~~~ {.rust}
65+
* ```rust
6666
* extern mod extra;
6767
* use extra::base64::{ToBase64, standard};
6868
*
6969
* fn main () {
7070
* let str = [52,32].to_base64(standard);
7171
* printfln!("%s", str);
7272
* }
73-
* ~~~
73+
* ```
7474
*/
7575
fn to_base64(&self, config: Config) -> ~str {
7676
let bytes = match config.char_set {
@@ -170,7 +170,7 @@ impl<'self> FromBase64 for &'self str {
170170
*
171171
* This converts a string literal to base64 and back.
172172
*
173-
* ~~~ {.rust}
173+
* ```rust
174174
* extern mod extra;
175175
* use extra::base64::{ToBase64, FromBase64, standard};
176176
* use std::str;
@@ -183,7 +183,7 @@ impl<'self> FromBase64 for &'self str {
183183
* let result_str = str::from_utf8(bytes);
184184
* printfln!("%s", result_str);
185185
* }
186-
* ~~~
186+
* ```
187187
*/
188188
fn from_base64(&self) -> Result<~[u8], ~str> {
189189
let mut r = ~[];

trunk/src/libextra/bitv.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -523,7 +523,7 @@ impl Bitv {
523523
* with the most significant bits of each byte coming first. Each
524524
* bit becomes true if equal to 1 or false if equal to 0.
525525
*/
526-
pub fn from_utf8(bytes: &[u8]) -> Bitv {
526+
pub fn from_bytes(bytes: &[u8]) -> Bitv {
527527
from_fn(bytes.len() * 8, |i| {
528528
let b = bytes[i / 8] as uint;
529529
let offset = i % 8;
@@ -1275,8 +1275,8 @@ mod tests {
12751275
}
12761276
12771277
#[test]
1278-
fn test_from_utf8() {
1279-
let bitv = from_utf8([0b10110110, 0b00000000, 0b11111111]);
1278+
fn test_from_bytes() {
1279+
let bitv = from_bytes([0b10110110, 0b00000000, 0b11111111]);
12801280
let str = ~"10110110" + "00000000" + "11111111";
12811281
assert_eq!(bitv.to_str(), str);
12821282
}
@@ -1302,7 +1302,7 @@ mod tests {
13021302
#[test]
13031303
fn test_to_bools() {
13041304
let bools = ~[false, false, true, false, false, true, true, false];
1305-
assert_eq!(from_utf8([0b00100110]).to_bools(), bools);
1305+
assert_eq!(from_bytes([0b00100110]).to_bools(), bools);
13061306
}
13071307
13081308
#[test]

trunk/src/libextra/crypto/md5.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ static C4: [u32, ..16] = [
156156

157157

158158
/// The MD5 Digest algorithm
159-
struct Md5 {
159+
pub struct Md5 {
160160
priv length_bytes: u64,
161161
priv buffer: FixedBuffer64,
162162
priv state: Md5State,

trunk/src/libextra/crypto/sha2.rs

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,8 @@ impl Engine512 {
230230
}
231231

232232

233-
struct Sha512 {
233+
/// The SHA-512 hash algorithm
234+
pub struct Sha512 {
234235
priv engine: Engine512
235236
}
236237

@@ -282,7 +283,8 @@ static H512: [u64, ..8] = [
282283
];
283284

284285

285-
struct Sha384 {
286+
/// The SHA-384 hash algorithm
287+
pub struct Sha384 {
286288
priv engine: Engine512
287289
}
288290

@@ -332,7 +334,8 @@ static H384: [u64, ..8] = [
332334
];
333335

334336

335-
struct Sha512Trunc256 {
337+
/// The SHA-512 hash algorithm with digest truncated to 256 bits
338+
pub struct Sha512Trunc256 {
336339
priv engine: Engine512
337340
}
338341

@@ -380,7 +383,8 @@ static H512_TRUNC_256: [u64, ..8] = [
380383
];
381384

382385

383-
struct Sha512Trunc224 {
386+
/// The SHA-512 hash algorithm with digest truncated to 224 bits
387+
pub struct Sha512Trunc224 {
384388
priv engine: Engine512
385389
}
386390

@@ -635,7 +639,8 @@ impl Engine256 {
635639
}
636640

637641

638-
struct Sha256 {
642+
/// The SHA-256 hash algorithm
643+
pub struct Sha256 {
639644
priv engine: Engine256
640645
}
641646

@@ -687,7 +692,8 @@ static H256: [u32, ..8] = [
687692
];
688693

689694

690-
struct Sha224 {
695+
/// The SHA-224 hash algorithm
696+
pub struct Sha224 {
691697
priv engine: Engine256
692698
}
693699

trunk/src/libextra/extra.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,7 @@ Rust extras are part of the standard Rust distribution.
2626
url = "https://github.com/mozilla/rust/tree/master/src/libextra")];
2727

2828
#[doc(html_logo_url = "http://www.rust-lang.org/logos/rust-logo-128x128-blk.png",
29-
html_favicon_url = "http://www.rust-lang.org/favicon.ico",
30-
passes = "strip-hidden")];
29+
html_favicon_url = "http://www.rust-lang.org/favicon.ico")];
3130

3231
#[comment = "Rust extras"];
3332
#[license = "MIT/ASL2"];

trunk/src/libextra/flatpipes.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ ports and channels.
2525
2626
This example sends boxed integers across tasks using serialization.
2727
28-
~~~ {.rust}
28+
```rust
2929
let (port, chan) = serial::pipe_stream();
3030
3131
do task::spawn || {
@@ -37,7 +37,7 @@ do task::spawn || {
3737
for i in range(0, 10) {
3838
assert @i == port.recv()
3939
}
40-
~~~
40+
```
4141
4242
# Safety Note
4343

trunk/src/libextra/future.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,13 @@
1414
*
1515
* # Example
1616
*
17-
* ~~~ {.rust}
17+
* ```rust
1818
* # fn fib(n: uint) -> uint {42};
1919
* # fn make_a_sandwich() {};
2020
* let mut delayed_fib = extra::future::spawn (|| fib(5000) );
2121
* make_a_sandwich();
2222
* printfln!("fib(5000) = %?", delayed_fib.get())
23-
* ~~~
23+
* ```
2424
*/
2525

2626
#[allow(missing_doc)];

trunk/src/libextra/getopts.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
//! that requires an input file to be specified, accepts an optional output
3030
//! file name following -o, and accepts both -h and --help as optional flags.
3131
//!
32-
//! ```
32+
//! ~~~{.rust}
3333
//! exter mod extra;
3434
//! use extra::getopts::*;
3535
//! use std::os;
@@ -75,7 +75,7 @@
7575
//! };
7676
//! do_work(input, output);
7777
//! }
78-
//! ```
78+
//! ~~~
7979
8080
use std::cmp::Eq;
8181
use std::result::{Err, Ok};

trunk/src/libextra/glob.rs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -51,18 +51,18 @@ pub struct GlobIterator {
5151
* Consider a directory `/media/pictures` containing only the files `kittens.jpg`,
5252
* `puppies.jpg` and `hamsters.gif`:
5353
*
54-
* ~~~ {.rust}
54+
* ```rust
5555
* for path in glob("/media/pictures/*.jpg") {
5656
* println(path.to_str());
5757
* }
58-
* ~~~
58+
* ```
5959
*
6060
* The above code will print:
6161
*
62-
* ~~~
62+
* ```
6363
* /media/pictures/kittens.jpg
6464
* /media/pictures/puppies.jpg
65-
* ~~~
65+
* ```
6666
*/
6767
pub fn glob(pattern: &str) -> GlobIterator {
6868
glob_with(pattern, MatchOptions::new())
@@ -270,11 +270,11 @@ impl Pattern {
270270
*
271271
* # Example
272272
*
273-
* ~~~ {.rust}
273+
* ```rust
274274
* assert!(Pattern::new("c?t").matches("cat"));
275275
* assert!(Pattern::new("k[!e]tteh").matches("kitteh"));
276276
* assert!(Pattern::new("d*g").matches("doog"));
277-
* ~~~
277+
* ```
278278
*/
279279
pub fn matches(&self, str: &str) -> bool {
280280
self.matches_with(str, MatchOptions::new())
@@ -492,13 +492,13 @@ impl MatchOptions {
492492
*
493493
* This function always returns this value:
494494
*
495-
* ~~~ {.rust}
495+
* ```rust
496496
* MatchOptions {
497497
* case_sensitive: true,
498498
* require_literal_separator: false.
499499
* require_literal_leading_dot: false
500500
* }
501-
* ~~~
501+
* ```
502502
*/
503503
pub fn new() -> MatchOptions {
504504
MatchOptions {

0 commit comments

Comments
 (0)