summaryrefslogtreecommitdiff
path: root/tests/static-1.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/static-1.c')
-rw-r--r--tests/static-1.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/static-1.c b/tests/static-1.c
new file mode 100644
index 0000000..cbdf07a
--- /dev/null
+++ b/tests/static-1.c
@@ -0,0 +1,9 @@
+// Files: static-1.c static-2.c
+// pp2cc should be able to compile two files with the same function defined,
+// but using static storage
+static int f() {
+ return 1;
+}
+int main() {
+ return f();
+}