about summary refs log tree commit diff
path: root/src/test/compile-fail/bad-for-loop.rs
AgeCommit message (Collapse)AuthorLines
2013-08-03replace all remaining `for` with `foreach` or `do`Daniel Micay-16/+0
2013-06-06test/compile-fail: clarify bad-for-loopRamkumar Ramachandra-3/+4
There are two distinct kinds of bad-for-loops to check for with two distinct error messages. The current bad-for-loop.rs does not make this clear, so rewrite it into bad-for-loop{,-2}.rs. The two failing prototypes are: fn quux(_: &fn(&int) -> int) -> bool { true } fn quux(_: &fn(&int) -> bool) -> () { } Note that the second one runs fine in rust-0.6 (the latest release), and only fails with a rust built from `incoming`. Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com>
2013-05-10test: Use the new `for` protocolAlex Crichton-0/+1
2013-03-11librustc: Replace all uses of `fn()` with `&fn()`. rs=defunPatrick Walton-1/+1
2013-01-24syntax/rustc: Improve error message for misuse of `for` loopTim Chevalier-1/+1
Print out a clearer error message when a `for` gets used with the wrong type of iterator. Also fix spans on `for` loop bodies, and suppress some more derived errors. r=brson Closes #3651
2012-12-10Reliciense makefiles and testsuite. Yup.Graydon Hoare-0/+10
2012-12-08Fix busted test caseTim Chevalier-1/+1
My last commit made more type errors recoverable, so extra errors that were getting suppressed before were unleashed.
2012-07-02Merge remote-tracking branch 'Dretch/prettydocs'Brian Anderson-1/+1
Conflicts: src/compiletest/errors.rs src/libsyntax/parse/attr.rs src/libsyntax/parse/comments.rs src/test/compile-fail/ambig_impl_unify.rs src/test/compile-fail/assign-super.rs src/test/compile-fail/bad-for-loop.rs src/test/compile-fail/bad-var-env-capture-in-block-arg.rs src/test/compile-fail/block-arg-as-stmt-with-value.rs src/test/compile-fail/borrowck-assign-comp-idx.rs src/test/compile-fail/borrowck-lend-flow.rs src/test/compile-fail/borrowck-loan-blocks-move-cc.rs src/test/compile-fail/borrowck-loan-blocks-mut-uniq.rs src/test/compile-fail/borrowck-loan-rcvr.rs src/test/compile-fail/borrowck-loan-vec-content.rs src/test/compile-fail/borrowck-mut-vec-as-imm-slice-bad.rs src/test/compile-fail/cap-clause-with-stack-closure.rs src/test/compile-fail/do1.rs src/test/compile-fail/do2.rs src/test/compile-fail/empty-vec-trailing-comma.rs src/test/compile-fail/evec-subtyping.rs src/test/compile-fail/issue-1896.rs src/test/compile-fail/issue-2149.rs src/test/compile-fail/issue-2150.rs src/test/compile-fail/issue-2487-b.rs src/test/compile-fail/kindck-implicit-close-over-mut-var.rs src/test/compile-fail/liveness-issue-2163.rs src/test/compile-fail/liveness-use-in-index-lvalue.rs src/test/compile-fail/no-reuse-move-arc.rs src/test/compile-fail/no-send-res-ports.rs src/test/compile-fail/non-const.rs src/test/compile-fail/pure-higher-order.rs src/test/compile-fail/pure-loop-body.rs src/test/compile-fail/regions-addr-of-upvar-self.rs src/test/compile-fail/regions-escape-loop-via-vec.rs src/test/compile-fail/regions-scoping.rs src/test/compile-fail/seq-args.rs src/test/compile-fail/tstate-unsat-in-called-fn-expr.rs src/test/compile-fail/tstate-unsat-in-fn-expr.rs src/test/compile-fail/vec-add.rs src/test/compile-fail/vec-concat-bug.rs src/test/compile-fail/vector-no-ann.rs
2012-07-01Convert to new closure syntaxBrian Anderson-1/+1
2012-06-30change the test suite `//! kind` syntax to `//~ kind` in order to avoid aGareth Daniel Smith-1/+1
conflict with the new single-line-sugared-inner-doc-comment (`//! ...`).
2012-04-23Emit a more useful error when using an unsuitable function for a loopMarijn Haverbeke-0/+4
Closes #2255