-
Notifications
You must be signed in to change notification settings - Fork 5.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allow symbols that begin with keywords. (#236)
* Fix opcode bug. * Remove unnecesary code from test.
- Loading branch information
1 parent
20401be
commit 6a3c580
Showing
4 changed files
with
176 additions
and
5 deletions.
There are no files selected for viewing
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
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
11 changes: 11 additions & 0 deletions
11
test/src/e2e_vm_tests/test_programs/fix_opcode_bug/Forc.toml
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,11 @@ | ||
[project] | ||
author = "Alexander Hansen <[email protected]>" | ||
license = "MIT" | ||
name = "asm_expr_basic" | ||
entry = "main.sw" | ||
|
||
|
||
[dependencies] | ||
std = { path = "../../../../../stdlib" } | ||
|
||
|
155 changes: 155 additions & 0 deletions
155
test/src/e2e_vm_tests/test_programs/fix_opcode_bug/src/main.sw
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,155 @@ | ||
script; | ||
|
||
fn abi_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn enum_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn fn_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn let_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn match_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn return_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn struct_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn trait_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn use_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn while_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn asm_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn as_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn contract_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn dep_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn deref_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn false_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn for_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn i64_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn impl_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn library_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn mut_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn predicate_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn pub_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn ref_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn script_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn self_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn str_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn true_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn u64_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn where_x() -> u64 { | ||
return 1; | ||
} | ||
|
||
fn main() -> u32 { | ||
let where_y = abi_x() | ||
+ enum_x() | ||
+ fn_x() | ||
+ let_x() | ||
+ match_x() | ||
+ return_x() | ||
+ struct_x() | ||
+ trait_x() | ||
+ use_x() | ||
+ while_x() | ||
+ asm_x() | ||
+ as_x() | ||
+ contract_x() | ||
+ dep_x() | ||
+ deref_x() | ||
+ false_x() | ||
+ for_x() | ||
+ i64_x() | ||
+ impl_x() | ||
+ library_x() | ||
+ mut_x() | ||
+ predicate_x() | ||
+ pub_x() | ||
+ ref_x() | ||
+ script_x() | ||
+ self_x() | ||
+ str_x() | ||
+ true_x() | ||
+ u64_x() | ||
+ where_x(); | ||
return where_y; | ||
} |