-
Notifications
You must be signed in to change notification settings - Fork 3.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Compiler-v2][trivial] fix error handling for
match
in expansion ph…
…ase (#15173) * fix * add error only when there isn't one
- Loading branch information
1 parent
9baf39b
commit 5fbf9b7
Showing
3 changed files
with
35 additions
and
5 deletions.
There are no files selected for viewing
7 changes: 7 additions & 0 deletions
7
third_party/move/move-compiler-v2/tests/checking/variants/bug_15073.exp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
|
||
Diagnostics: | ||
error: unbound module | ||
┌─ tests/checking/variants/bug_15073.move:8:13 | ||
│ | ||
8 │ ToolType::Http { uri } => { | ||
│ ^^^^^^^^ Unbound module or type alias 'ToolType' |
14 changes: 14 additions & 0 deletions
14
third_party/move/move-compiler-v2/tests/checking/variants/bug_15073.move
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
module 0x815::m { | ||
|
||
public fun init_registration( | ||
creator: &signer, | ||
tool_type: ToolType | ||
) { | ||
match(tool_type) { | ||
ToolType::Http { uri } => { | ||
|
||
}, | ||
} | ||
|
||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters