File tree Expand file tree Collapse file tree 2 files changed +22
-2
lines changed Expand file tree Collapse file tree 2 files changed +22
-2
lines changed Original file line number Diff line number Diff line change @@ -11113,7 +11113,7 @@ Parser<ManagedTokenSource>::parse_identifier_pattern ()
11113
11113
lexer.skip_token ();
11114
11114
11115
11115
// parse required pattern to bind
11116
- bind_pattern = parse_pattern ();
11116
+ bind_pattern = parse_pattern_no_alt ();
11117
11117
if (bind_pattern == nullptr )
11118
11118
{
11119
11119
Error error (lexer.peek_token ()->get_locus (),
@@ -11240,7 +11240,8 @@ Parser<ManagedTokenSource>::parse_ident_leading_pattern ()
11240
11240
// identifier with pattern bind
11241
11241
lexer.skip_token ();
11242
11242
11243
- std::unique_ptr<AST::Pattern> bind_pattern = parse_pattern ();
11243
+ std::unique_ptr<AST::Pattern> bind_pattern
11244
+ = parse_pattern_no_alt ();
11244
11245
if (bind_pattern == nullptr )
11245
11246
{
11246
11247
Error error (
Original file line number Diff line number Diff line change
1
+ // { dg-additional-options "-frust-compile-until=typecheck" }
2
+ // TODO: this should typecheck
3
+
4
+ #[ lang = "sized" ]
5
+ trait Sized { }
6
+
7
+ #[ lang = "fn_once" ]
8
+ pub trait FnOnce < Args > {
9
+ /// The returned type after the call operator is used.
10
+ #[ lang = "fn_once_output" ]
11
+ type Output ;
12
+
13
+ /// Performs the call operation.
14
+ extern "rust-call" fn call_once ( self , args : Args ) -> Self :: Output ;
15
+ }
16
+
17
+ pub fn foo ( ) {
18
+ ( |_a @ _b| { } ) ( 1 )
19
+ }
You can’t perform that action at this time.
0 commit comments