-
Notifications
You must be signed in to change notification settings - Fork 63
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: resource shadowing cross-reference case (#340)
- Loading branch information
1 parent
e6325fa
commit 1f85139
Showing
9 changed files
with
84 additions
and
31 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
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
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
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
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,34 @@ | ||
package jcbhmr:hello-world-rust-wasm-component-lib; | ||
|
||
interface cbh { | ||
resource p-string { | ||
call: func(a: string); | ||
} | ||
resource r-string { | ||
call: func() -> string; | ||
} | ||
} | ||
interface cb { | ||
use cbh.{p-string as h-p-string, r-string as h-r-string}; | ||
resource p-string { | ||
constructor(cb: h-p-string); | ||
call: func(a: string); | ||
} | ||
resource r-string { | ||
constructor(cb: h-r-string); | ||
call: func() -> string; | ||
} | ||
} | ||
|
||
interface hello-world { | ||
use cb.{p-string, r-string}; | ||
set-cb: func(cb: p-string); | ||
run-cb-with-result-of: func(cb: borrow<r-string>); | ||
} | ||
|
||
world hello-world-rust-wasm-component-lib { | ||
import cbh; | ||
export cb; | ||
|
||
export hello-world; | ||
} |