From 01406ad25ff49d5c5f722f34187d2063cefea5ed Mon Sep 17 00:00:00 2001 From: pacien Date: Wed, 6 Jun 2018 14:14:55 +0200 Subject: require main func and rename tests --- res/test_sample_ko.tpc | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 res/test_sample_ko.tpc (limited to 'res/test_sample_ko.tpc') diff --git a/res/test_sample_ko.tpc b/res/test_sample_ko.tpc new file mode 100644 index 0000000..9dc344f --- /dev/null +++ b/res/test_sample_ko.tpc @@ -0,0 +1,24 @@ +/** + * UPEM / Compilation / Projet TPC + * Exemple de fichier source TPC invalide + * Pacien TRAN-GIRARD, Adam NAILI + */ + +const special = 'b'; + +caractere funky_func(entier arg) { + return !arg; +} + +void main(void) { + void ret; + ret = 1 + funky_func(0) * 2; + + while (ret) { + readc(ret); + print(ret); + + if (ret == special) print('!'); + } +} + -- cgit v1.2.3