-
Notifications
You must be signed in to change notification settings - Fork 243
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixes an issue where we would rewrite structs and their fields even though they appear in extern blocks.
- Loading branch information
1 parent
a4ab0bc
commit b90b646
Showing
5 changed files
with
84 additions
and
11 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
extern "Rust" { | ||
fn foo(bar: Alias) -> Baz; | ||
} | ||
|
||
type Alias = Bar; | ||
|
||
// CHECK-DAG: p: (g1) perms = UNIQUE, flags = FIXED | ||
// CHECK-DAG: p: (g2) perms = UNIQUE, flags = FIXED | ||
|
||
// CHECK-DAG: struct Bar | ||
struct Bar { | ||
// CHECK-DAG: p: *mut i32 | ||
p: *mut i32 | ||
} | ||
|
||
// CHECK-DAG: struct Baz | ||
struct Baz { | ||
// CHECK-DAG: p: *mut i32 | ||
p: *mut i32 | ||
} | ||
|
||
// we need something to get rewritten in order | ||
// to check that `Bar` and `Baz` get output | ||
// in the rewrite string | ||
fn fizz(i: *const i32) {} |