]> git.sur5r.net Git - cc65/commitdiff
New test program arg-test.c
authorcuz <cuz@b7a2c559-68d2-44c3-8de9-860c34a00d81>
Sun, 2 May 2004 00:53:39 +0000 (00:53 +0000)
committercuz <cuz@b7a2c559-68d2-44c3-8de9-860c34a00d81>
Sun, 2 May 2004 00:53:39 +0000 (00:53 +0000)
git-svn-id: svn://svn.cc65.org/cc65/trunk@3003 b7a2c559-68d2-44c3-8de9-860c34a00d81

testcode/lib/arg-test.c [new file with mode: 0644]
testcode/lib/files.txt

diff --git a/testcode/lib/arg-test.c b/testcode/lib/arg-test.c
new file mode 100644 (file)
index 0000000..c752aca
--- /dev/null
@@ -0,0 +1,16 @@
+#include <stdio.h>
+#include <stdlib.h>
+
+int main (int argc, char* argv[])
+{
+    int I;
+
+    printf ("argc:     %d\n", argc);
+    for (I = 0; I < argc; ++I) {
+        printf ("argv[%2d]: \"%s\"\n", I, argv[I]);
+    }
+    return EXIT_SUCCESS;
+}
+
+
+
index f7623eaf4826c591c31f439667b33cfe29a30b58..a599d20dc6015b25fbc02925cf52645840acee4e 100644 (file)
@@ -2,6 +2,7 @@
 Test programs for the runtime lib:
 ----------------------------------
 
+arg-test.c     -       test program for passing arguments to main()
 clock.c                -       test program for clock() and CLOCKS_PER_SEC
 cprintf.c      -       test program for cprintf \n and \r operators
 cursor.c       -       test the cursor() function