mirror of
https://github.com/mirror/tinycc.git
synced 2026-09-03 12:12:46 +08:00
fix: previous two commits
This commit is contained in:
1
tests/tests2/133_exec_section_in_asm.expect
Normal file
1
tests/tests2/133_exec_section_in_asm.expect
Normal file
@@ -0,0 +1 @@
|
||||
AAAAAAAAA
|
||||
@@ -1,3 +1,5 @@
|
||||
#include <stdio.h>
|
||||
|
||||
/* Previously in TinyCC, ELF sections defined in attributes would always have
|
||||
the execute bit not set, so you would get segmentation faults when code in these
|
||||
sections was exectuted. This file is a minimal example of a file that will put
|
||||
@@ -9,5 +11,7 @@ int wumbo (int arg) {
|
||||
}
|
||||
|
||||
int main () {
|
||||
return wumbo(2);
|
||||
wumbo(2);
|
||||
puts("hi");
|
||||
return 0;
|
||||
}
|
||||
1
tests/tests2/134_exec_section_in_c.expect
Normal file
1
tests/tests2/134_exec_section_in_c.expect
Normal file
@@ -0,0 +1 @@
|
||||
hi
|
||||
@@ -1,13 +0,0 @@
|
||||
int main () {
|
||||
// This used to evaluate to 0 (0), which is invalid.
|
||||
// Now it should evaluate to 0.
|
||||
#if WUMBOED(WUMBO)
|
||||
#endif
|
||||
|
||||
// Just trying a more complicated test case.
|
||||
#if WUMBO && defined(WUMBOLOGY) || WUMBOED(WUMBO) && !WUMBOLOGY
|
||||
return 0;
|
||||
#elif WUMBO && defined(WUMBOLOGY) || WUMBOED(WUMBO) && !WUMBOLOGY
|
||||
return 1;
|
||||
#endif
|
||||
}
|
||||
Reference in New Issue
Block a user