forked from FuelLabs/sway
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Clean up go to definition tests and adds a test for variable tokens (F…
…uelLabs#3955) This PR cleans up the go_to testing code so it's easier to use. I've also added a new example so we can test the definition response of variables in the following cases: - Variable expressions - Function arguments - Struct fields - Enum fields - Tuple elements - Array elements - Scoped declarations - If let scopes - Shadowing --------- Co-authored-by: Sophie Dankel <[email protected]>
- Loading branch information
1 parent
ddb0ede
commit dd9ab73
Showing
7 changed files
with
266 additions
and
119 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
[[package]] | ||
name = 'core' | ||
source = 'path+from-root-C35A83477D5B662F' | ||
source = 'path+from-root-70DB58A2053CC06C' | ||
|
||
[[package]] | ||
name = 'std' | ||
source = 'path+from-root-70DB58A2053CC06C' | ||
dependencies = ['core'] | ||
|
||
[[package]] | ||
name = 'turbofish' | ||
source = 'member' | ||
dependencies = ['std'] | ||
|
||
[[package]] | ||
name = 'std' | ||
source = 'path+from-root-C35A83477D5B662F' | ||
dependencies = ['core'] |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
out | ||
target |
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,13 @@ | ||
[[package]] | ||
name = 'core' | ||
source = 'path+from-root-516E592B177796C8' | ||
|
||
[[package]] | ||
name = 'std' | ||
source = 'path+from-root-516E592B177796C8' | ||
dependencies = ['core'] | ||
|
||
[[package]] | ||
name = 'variables' | ||
source = 'member' | ||
dependencies = ['std'] |
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,8 @@ | ||
[project] | ||
authors = ["Fuel Labs <[email protected]>"] | ||
entry = "main.sw" | ||
license = "Apache-2.0" | ||
name = "variables" | ||
|
||
[dependencies] | ||
std = { path = "../../../../../sway-lib-std" } |
Oops, something went wrong.