about summary refs log tree commit diff
path: root/src/libsyntax/parse
diff options
context:
space:
mode:
authorkennytm <kennytm@gmail.com>2017-10-13 23:37:54 +0800
committerGitHub <noreply@github.com>2017-10-13 23:37:54 +0800
commit9eab4ec823c9f7a19ac9516e3858891b46225828 (patch)
treed8be29874e18185f313d1f4ad7765c9c17d020bb /src/libsyntax/parse
parent82f2c28bc831ff9ec16e0144c2cf73769f85f1de (diff)
parentdb91b00065181137fa4a298aeee796ff10755d20 (diff)
downloadrust-9eab4ec823c9f7a19ac9516e3858891b46225828.tar.gz
rust-9eab4ec823c9f7a19ac9516e3858891b46225828.zip
Rollup merge of #45122 - jean-lourenco:master, r=nikomatsakis
Better compile error output when using arguments instead of types

Following @estebank sugestion on issue https://github.com/rust-lang/rust/issues/18945#issuecomment-331251436
Diffstat (limited to 'src/libsyntax/parse')
-rw-r--r--src/libsyntax/parse/parser.rs1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs
index ff020445715..6dbda11e021 100644
--- a/src/libsyntax/parse/parser.rs
+++ b/src/libsyntax/parse/parser.rs
@@ -2960,6 +2960,7 @@ impl<'a> Parser<'a> {
                 {                                  //     Foo<Bar<Baz<Qux, ()>>>
                     err.help(
                         "use `::<...>` instead of `<...>` if you meant to specify type arguments");
+                    err.help("or use `(...)` if you meant to specify fn arguments");
                 }
                 err.emit();
             }