Commit 8df6df3
committed
[android][test] Explicitly sign chars to match expectations
`char` is not always signed by default. In fact, the signedness
of the `char` datatype in C is undefined. That means that on some
architectures, the `c_layout.sil` test fails, because it expects
the IR for `char chareth(char a);` to use `signedext`, whereas
some architectures treat these types as unsigned, and thus
`zeroext` is used.
In order to ensure identical signedness on all platforms the tests
run on, explicitly specify the signedness using the compiler flag
`-fsigned-char`.
It would be better to test the signedness for each platform, as
suggested in swiftlang#1103. This is an
interim solution.1 parent 5b1d25f commit 8df6df3
1 file changed
+3
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
| 2 | + | |
| 3 | + | |
2 | 4 | | |
3 | 5 | | |
4 | 6 | | |
| |||
0 commit comments