Skip to content

Commit 2290d23

Browse files
committed
---
yaml --- r: 209910 b: refs/heads/try c: 4f1bbc2 h: refs/heads/master v: v3
1 parent 4e9b810 commit 2290d23

File tree

502 files changed

+7499
-10613
lines changed

Some content is hidden

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

502 files changed

+7499
-10613
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
refs/heads/master: 3e561f05c00cd180ec02db4ccab2840a4aba93d2
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: ba0e1cd8147d452c356aacb29fb87568ca26f111
5-
refs/heads/try: ba4d55d130f9577eddf577b9bf99562a8c65857b
5+
refs/heads/try: 4f1bbc209fbf79ed5143ec4f5d78333dab4ba39d
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/dist-snap: ba4081a5a8573875fed17545846f6f6902c8ba8d
88
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596

branches/try/configure

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -337,6 +337,15 @@ to_gnu_triple() {
337337
esac
338338
}
339339

340+
# Prints the absolute path of a directory to stdout
341+
abs_path() {
342+
local _path="$1"
343+
# Unset CDPATH because it causes havok: it makes the destination unpredictable
344+
# and triggers 'cd' to print the path to stdout. Route `cd`'s output to /dev/null
345+
# for good measure.
346+
(unset CDPATH && cd "$_path" > /dev/null && pwd)
347+
}
348+
340349
msg "looking for configure programs"
341350
need_cmd cmp
342351
need_cmd mkdir
@@ -509,7 +518,7 @@ fi
509518

510519
DEFAULT_BUILD="${CFG_CPUTYPE}-${CFG_OSTYPE}"
511520

512-
CFG_SRC_DIR="$(cd $(dirname $0) && pwd)/"
521+
CFG_SRC_DIR="$(abs_path $(dirname $0))/"
513522
CFG_BUILD_DIR="$(pwd)/"
514523
CFG_SELF="$0"
515524
CFG_CONFIGURE_ARGS="$@"

branches/try/mk/main.mk

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,12 @@
1313
######################################################################
1414

1515
# The version number
16-
CFG_RELEASE_NUM=1.0.0
16+
CFG_RELEASE_NUM=1.1.0
1717

1818
# An optional number to put after the label, e.g. '.2' -> '-beta.2'
1919
# NB Make sure it starts with a dot to conform to semver pre-release
2020
# versions (section 9)
21-
CFG_PRERELEASE_VERSION=.3
21+
CFG_PRERELEASE_VERSION=.1
2222

2323
CFG_FILENAME_EXTRA=4e7c5e5c
2424

@@ -30,8 +30,12 @@ CFG_PACKAGE_VERS=$(CFG_RELEASE_NUM)
3030
CFG_DISABLE_UNSTABLE_FEATURES=1
3131
endif
3232
ifeq ($(CFG_RELEASE_CHANNEL),beta)
33-
CFG_RELEASE=$(CFG_RELEASE_NUM)-beta$(CFG_PRERELEASE_VERSION)
34-
CFG_PACKAGE_VERS=$(CFG_RELEASE_NUM)-beta$(CFG_PRERELEASE_VERSION)
33+
CFG_RELEASE=$(CFG_RELEASE_NUM)-beta
34+
# When building beta distributables just reuse the same "beta" name
35+
# so when we upload we'll always override the previous beta. This
36+
# doesn't actually impact the version reported by rustc - it's just
37+
# for file naming.
38+
CFG_PACKAGE_VERS=beta
3539
CFG_DISABLE_UNSTABLE_FEATURES=1
3640
endif
3741
ifeq ($(CFG_RELEASE_CHANNEL),nightly)

branches/try/mk/tests.mk

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -753,20 +753,22 @@ PRETTY_DEPS_pretty-rpass-full = $(RPASS_FULL_TESTS)
753753
PRETTY_DEPS_pretty-rfail = $(RFAIL_TESTS)
754754
PRETTY_DEPS_pretty-bench = $(BENCH_TESTS)
755755
PRETTY_DEPS_pretty-pretty = $(PRETTY_TESTS)
756-
# The stage- and host-specific dependencies are for e.g. macro_crate_test which pulls in
757-
# external crates.
758-
PRETTY_DEPS$(1)_H_$(3)_pretty-rpass =
759-
PRETTY_DEPS$(1)_H_$(3)_pretty-rpass-full = $$(HLIB$(1)_H_$(3))/stamp.syntax $$(HLIB$(1)_H_$(3))/stamp.rustc
760-
PRETTY_DEPS$(1)_H_$(3)_pretty-rfail =
761-
PRETTY_DEPS$(1)_H_$(3)_pretty-bench =
762-
PRETTY_DEPS$(1)_H_$(3)_pretty-pretty =
763756
PRETTY_DIRNAME_pretty-rpass = run-pass
764757
PRETTY_DIRNAME_pretty-rpass-valgrind = run-pass-valgrind
765758
PRETTY_DIRNAME_pretty-rpass-full = run-pass-fulldeps
766759
PRETTY_DIRNAME_pretty-rfail = run-fail
767760
PRETTY_DIRNAME_pretty-bench = bench
768761
PRETTY_DIRNAME_pretty-pretty = pretty
769762

763+
define DEF_PRETTY_FULLDEPS
764+
PRETTY_DEPS$(1)_T_$(2)_H_$(3)_pretty-rpass-full = $$(CSREQ$(1)_T_$(3)_H_$(3))
765+
endef
766+
767+
$(foreach host,$(CFG_HOST), \
768+
$(foreach target,$(CFG_TARGET), \
769+
$(foreach stage,$(STAGES), \
770+
$(eval $(call DEF_PRETTY_FULLDEPS,$(stage),$(target),$(host))))))
771+
770772
define DEF_RUN_PRETTY_TEST
771773

772774
PRETTY_ARGS$(1)-T-$(2)-H-$(3)-$(4) := \
@@ -780,7 +782,7 @@ check-stage$(1)-T-$(2)-H-$(3)-$(4)-exec: $$(call TEST_OK_FILE,$(1),$(2),$(3),$(4
780782
$$(call TEST_OK_FILE,$(1),$(2),$(3),$(4)): \
781783
$$(TEST_SREQ$(1)_T_$(2)_H_$(3)) \
782784
$$(PRETTY_DEPS_$(4)) \
783-
$$(PRETTY_DEPS$(1)_H_$(3)_$(4))
785+
$$(PRETTY_DEPS$(1)_T_$(2)_H_$(3)_$(4))
784786
@$$(call E, run pretty-rpass [$(2)]: $$<)
785787
$$(Q)touch $$@.start_time
786788
$$(Q)$$(call CFG_RUN_CTEST_$(2),$(1),$$<,$(3)) \

branches/try/src/compiletest/runtest.rs

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -979,13 +979,25 @@ fn check_expected_errors(expected_errors: Vec<errors::ExpectedError> ,
979979
// is the ending point, and * represents ANSI color codes.
980980
for line in proc_res.stderr.lines() {
981981
let mut was_expected = false;
982+
let mut prev = 0;
982983
for (i, ee) in expected_errors.iter().enumerate() {
983984
if !found_flags[i] {
984985
debug!("prefix={} ee.kind={} ee.msg={} line={}",
985986
prefixes[i],
986987
ee.kind,
987988
ee.msg,
988989
line);
990+
// Suggestions have no line number in their output, so take on the line number of
991+
// the previous expected error
992+
if ee.kind == "suggestion" {
993+
assert!(expected_errors[prev].kind == "help",
994+
"SUGGESTIONs must be preceded by a HELP");
995+
if line.contains(&ee.msg) {
996+
found_flags[i] = true;
997+
was_expected = true;
998+
break;
999+
}
1000+
}
9891001
if (prefix_matches(line, &prefixes[i]) || continuation(line)) &&
9901002
line.contains(&ee.kind) &&
9911003
line.contains(&ee.msg) {
@@ -994,6 +1006,7 @@ fn check_expected_errors(expected_errors: Vec<errors::ExpectedError> ,
9941006
break;
9951007
}
9961008
}
1009+
prev = i;
9971010
}
9981011

9991012
// ignore this msg which gets printed at the end
@@ -1452,7 +1465,7 @@ fn make_out_name(config: &Config, testfile: &Path, extension: &str) -> PathBuf {
14521465
fn aux_output_dir_name(config: &Config, testfile: &Path) -> PathBuf {
14531466
let f = output_base_name(config, testfile);
14541467
let mut fname = f.file_name().unwrap().to_os_string();
1455-
fname.push("libaux");
1468+
fname.push(&format!(".{}.libaux", config.mode));
14561469
f.with_file_name(&fname)
14571470
}
14581471

branches/try/src/doc/grammar.md

Lines changed: 24 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -152,19 +152,19 @@ token : simple_token | ident | literal | symbol | whitespace token ;
152152

153153
<p id="keyword-table-marker"></p>
154154

155-
| | | | | |
156-
|----------|----------|----------|----------|--------|
157-
| abstract | alignof | as | become | box |
158-
| break | const | continue | crate | do |
159-
| else | enum | extern | false | final |
160-
| fn | for | if | impl | in |
161-
| let | loop | match | mod | move |
162-
| mut | offsetof | once | override | priv |
163-
| proc | pub | pure | ref | return |
164-
| sizeof | static | self | struct | super |
165-
| true | trait | type | typeof | unsafe |
166-
| unsized | use | virtual | where | while |
167-
| yield | | | | |
155+
| | | | | |
156+
|----------|----------|----------|----------|---------|
157+
| abstract | alignof | as | become | box |
158+
| break | const | continue | crate | do |
159+
| else | enum | extern | false | final |
160+
| fn | for | if | impl | in |
161+
| let | loop | macro | match | mod |
162+
| move | mut | offsetof | override | priv |
163+
| proc | pub | pure | ref | return |
164+
| Self | self | sizeof | static | struct |
165+
| super | trait | true | type | typeof |
166+
| unsafe | unsized | use | virtual | where |
167+
| while | yield | | | |
168168

169169

170170
Each of these keywords has special meaning in its grammar, and all of them are
@@ -524,6 +524,15 @@ array_elems : [expr [',' expr]*] | [expr ',' ".." expr] ;
524524
idx_expr : expr '[' expr ']' ;
525525
```
526526

527+
### Range expressions
528+
529+
```antlr
530+
range_expr : expr ".." expr |
531+
expr ".." |
532+
".." expr |
533+
".." ;
534+
```
535+
527536
### Unary operator expressions
528537

529538
**FIXME:** grammar?
@@ -610,7 +619,7 @@ lambda_expr : '|' ident_list '|' expr ;
610619
### While loops
611620

612621
```antlr
613-
while_expr : "while" no_struct_literal_expr '{' block '}' ;
622+
while_expr : [ lifetime ':' ] "while" no_struct_literal_expr '{' block '}' ;
614623
```
615624

616625
### Infinite loops
@@ -634,7 +643,7 @@ continue_expr : "continue" [ lifetime ];
634643
### For expressions
635644

636645
```antlr
637-
for_expr : "for" pat "in" no_struct_literal_expr '{' block '}' ;
646+
for_expr : [ lifetime ':' ] "for" pat "in" no_struct_literal_expr '{' block '}' ;
638647
```
639648

640649
### If expressions

0 commit comments

Comments
 (0)