Skip to content

Commit 5b3e7e5

Browse files
committed
Fix issue 207 by considering everything after the first : in the error-pattern
line.
1 parent 1b82060 commit 5b3e7e5

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

src/Makefile

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -681,25 +681,24 @@ test/run-fail/%.out.tmp: test/run-fail/%$(CFG_EXE_SUFFIX) \
681681
$(CFG_QUIET)$(call CFG_RUN_TARG, $<) >$@ 2>&1 ; X=$$? ; \
682682
if [ $$X -eq 0 ] ; then exit 1 ; else exit 0 ; fi
683683
$(CFG_QUIET)grep --text --quiet \
684-
"`awk -F: '/error-pattern/ { print $$2 }' \
685-
test/run-fail/$(basename $*).rs \
686-
| tr -d '\n\r'`" $@
684+
"$$(grep error-pattern test/run-fail/$(basename $*).rs \
685+
| cut -d : -f 2- | tr -d '\n\r')" $@
687686

688687
test/compile-fail/%.boot.out.tmp: test/compile-fail/%.rs $(BREQ)
689688
@$(call CFG_ECHO, compile [boot]: $<)
690689
$(CFG_QUIET)grep -q error-pattern $<
691690
$(CFG_QUIET)rm -f $@
692691
$(BOOT) -o $(@:.out=$(CFG_EXE_SUFFIX)) $< >$@ 2>&1; test $$? -ne 0
693692
$(CFG_QUIET)grep --text --quiet \
694-
"`awk -F: '/error-pattern/ { print $$2 }' $< | tr -d '\n\r'`" $@
693+
"$$(grep error-pattern $< | cut -d : -f 2- | tr -d '\n\r')" $@
695694

696695
test/compile-fail/%.rustc.out.tmp: test/compile-fail/%.rs $(SREQ)
697696
@$(call CFG_ECHO, compile [rustc]: $<)
698697
$(CFG_QUIET)grep -q error-pattern $<
699698
$(CFG_QUIET)rm -f $@
700699
$(RUSTC) -o $(@:.out=$(CFG_EXE_SUFFIX)) $< >$@ 2>&1; test $$? -ne 0
701700
$(CFG_QUIET)grep --text --quiet \
702-
"`awk -F: '/error-pattern/ { print $$2 }' $< | tr -d '\n\r'`" $@
701+
"$$(grep error-pattern $< | cut -d : -f 2- | tr -d '\n\r')" $@
703702

704703
test/run-pass/%.boot$(CFG_EXE_SUFFIX): test/run-pass/%.rc $(BREQ)
705704
@$(call CFG_ECHO, compile [boot]: $<)

0 commit comments

Comments
 (0)