-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rename generated structures to
Guest
in bindgen (#7794)
This mirrors how traits for the host are all called `Host` and it avoids name clashes with types that share the name of the interface they are in. I've also added some simple debugging of macro-generated code to get better error messages. Closes #7775
- Loading branch information
1 parent
e5817d9
commit 38421d6
Showing
4 changed files
with
56 additions
and
18 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
fn main() { | ||
println!("cargo:rerun-if-changed=build.rs"); | ||
let out_dir = std::env::var("OUT_DIR").unwrap(); | ||
println!("cargo:rustc-env=DEBUG_OUTPUT_DIR={out_dir}"); | ||
} |
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,10 @@ | ||
package same:name; | ||
|
||
interface this-name-is-duplicated { | ||
resource this-name-is-duplicated { | ||
} | ||
} | ||
|
||
world example { | ||
export this-name-is-duplicated; | ||
} |
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