diff --git a/M2libc b/M2libc index db93c71..5acfc85 160000 --- a/M2libc +++ b/M2libc @@ -1 +1 @@ -Subproject commit db93c7178e028ac6f0bcecc2b100a984bfba13a9 +Subproject commit 5acfc8584dfeb122181217a9e75bff4185d9a1d8 diff --git a/cc-minimal.c b/cc-minimal.c index 2555cde..b0fbdc3 100644 --- a/cc-minimal.c +++ b/cc-minimal.c @@ -26,7 +26,6 @@ struct token_list* reverse_list(struct token_list* head); struct token_list* program(); void recursive_output(struct token_list* i, FILE* out); int match(char* a, char* b); -void file_print(char* s, FILE* f); char* parse_string(char* string); int main() @@ -43,7 +42,7 @@ int main() if(NULL == global_token) { - file_print("Either no input files were given or they were empty\n", stderr); + fputs("Either no input files were given or they were empty\n", stderr); exit(EXIT_FAILURE); } global_token = reverse_list(global_token); @@ -54,14 +53,14 @@ int main() program(); /* Output the program we have compiled */ - file_print("\n# Core program\n", destination_file); + fputs("\n# Core program\n", destination_file); recursive_output(output_list, destination_file); - file_print("\n\n# Program global variables\n", destination_file); + fputs("\n\n# Program global variables\n", destination_file); recursive_output(globals_list, destination_file); - file_print("\n# Program strings\n", destination_file); + fputs("\n# Program strings\n", destination_file); recursive_output(strings_list, destination_file); - file_print("\n:STACK\n", destination_file); + fputs("\n:STACK\n", destination_file); - fclose(destination_file) + fclose(destination_file); return EXIT_SUCCESS; } diff --git a/cc.c b/cc.c index 7645238..f9f1f5a 100644 --- a/cc.c +++ b/cc.c @@ -71,9 +71,9 @@ int main(int argc, char** argv) in = fopen(name, "r"); if(NULL == in) { - file_print("Unable to open for reading file: ", stderr); - file_print(name, stderr); - file_print("\n Aborting to avoid problems\n", stderr); + fputs("Unable to open for reading file: ", stderr); + fputs(name, stderr); + fputs("\n Aborting to avoid problems\n", stderr); exit(EXIT_FAILURE); } global_token = read_all_tokens(in, global_token, name); @@ -85,9 +85,9 @@ int main(int argc, char** argv) destination_file = fopen(argv[i + 1], "w"); if(NULL == destination_file) { - file_print("Unable to open for writing file: ", stderr); - file_print(argv[i + 1], stderr); - file_print("\n Aborting to avoid problems\n", stderr); + fputs("Unable to open for writing file: ", stderr); + fputs(argv[i + 1], stderr); + fputs("\n Aborting to avoid problems\n", stderr); exit(EXIT_FAILURE); } i = i + 2; @@ -103,9 +103,9 @@ int main(int argc, char** argv) else if(match("aarch64", arch)) Architecture = AARCH64; else { - file_print("Unknown architecture: ", stderr); - file_print(arch, stderr); - file_print(" know values are: knight-native, knight-posix, x86, amd64, armv7l and aarch64", stderr); + fputs("Unknown architecture: ", stderr); + fputs(arch, stderr); + fputs(" know values are: knight-native, knight-posix, x86, amd64, armv7l and aarch64", stderr); exit(EXIT_FAILURE); } i = i + 2; @@ -128,7 +128,7 @@ int main(int argc, char** argv) } else if(match(argv[i], "-h") || match(argv[i], "--help")) { - file_print(" -f input file\n -o output file\n --help for this message\n --version for file version\n", stdout); + fputs(" -f input file\n -o output file\n --help for this message\n --version for file version\n", stdout); exit(EXIT_SUCCESS); } else if(match(argv[i], "-E")) @@ -155,12 +155,12 @@ int main(int argc, char** argv) } else if(match(argv[i], "-V") || match(argv[i], "--version")) { - file_print("M2-Planet v1.7.0\n", stderr); + fputs("M2-Planet v1.7.0\n", stderr); exit(EXIT_SUCCESS); } else { - file_print("UNKNOWN ARGUMENT\n", stdout); + fputs("UNKNOWN ARGUMENT\n", stdout); exit(EXIT_FAILURE); } } @@ -175,7 +175,7 @@ int main(int argc, char** argv) if(NULL == global_token) { - file_print("Either no input files were given or they were empty\n", stderr); + fputs("Either no input files were given or they were empty\n", stderr); exit(EXIT_FAILURE); } global_token = reverse_list(global_token); @@ -193,7 +193,7 @@ int main(int argc, char** argv) if (PREPROCESSOR_MODE) { - file_print("\n/* Preprocessed source */\n", destination_file); + fputs("\n/* Preprocessed source */\n", destination_file); output_tokens(global_token, destination_file); goto exit_success; } @@ -207,16 +207,16 @@ int main(int argc, char** argv) program(); /* Output the program we have compiled */ - file_print("\n# Core program\n", destination_file); + fputs("\n# Core program\n", destination_file); recursive_output(output_list, destination_file); - if(KNIGHT_NATIVE == Architecture) file_print("\n", destination_file); - else if(DEBUG) file_print("\n:ELF_data\n", destination_file); - file_print("\n# Program global variables\n", destination_file); + if(KNIGHT_NATIVE == Architecture) fputs("\n", destination_file); + else if(DEBUG) fputs("\n:ELF_data\n", destination_file); + fputs("\n# Program global variables\n", destination_file); recursive_output(globals_list, destination_file); - file_print("\n# Program strings\n", destination_file); + fputs("\n# Program strings\n", destination_file); recursive_output(strings_list, destination_file); - if(KNIGHT_NATIVE == Architecture) file_print("\n:STACK\n", destination_file); - else if(!DEBUG) file_print("\n:ELF_end\n", destination_file); + if(KNIGHT_NATIVE == Architecture) fputs("\n:STACK\n", destination_file); + else if(!DEBUG) fputs("\n:ELF_end\n", destination_file); exit_success: if (destination_file != stdout) diff --git a/cc.h b/cc.h index 3361dc1..8166265 100644 --- a/cc.h +++ b/cc.h @@ -42,7 +42,6 @@ void copy_string(char* target, char* source, int max); int in_set(int c, char* s); int match(char* a, char* b); -void file_print(char* s, FILE* f); void require(int bool, char* error); void reset_hold_string(); diff --git a/cc_core.c b/cc_core.c index 17195d2..c4a584a 100644 --- a/cc_core.c +++ b/cc_core.c @@ -98,10 +98,10 @@ struct token_list* sym_lookup(char *s, struct token_list* symbol_list) void line_error_token(struct token_list *token) { require(NULL != token, "EOF reached inside of line_error\n"); - file_print(token->filename, stderr); - file_print(":", stderr); - file_print(numerate_number(token->linenumber), stderr); - file_print(":", stderr); + fputs(token->filename, stderr); + fputs(":", stderr); + fputs(numerate_number(token->linenumber), stderr); + fputs(":", stderr); } void line_error() @@ -115,7 +115,7 @@ void require_match(char* message, char* required) if(!match(global_token->s, required)) { line_error(); - file_print(message, stderr); + fputs(message, stderr); exit(EXIT_FAILURE); } global_token = global_token->next; @@ -127,8 +127,8 @@ void maybe_bootstrap_error(char* feature) if (BOOTSTRAP_MODE) { line_error(); - file_print(feature, stderr); - file_print(" is not supported in --bootstrap-mode\n", stderr); + fputs(feature, stderr); + fputs(" is not supported in --bootstrap-mode\n", stderr); exit(EXIT_FAILURE); } } @@ -421,9 +421,9 @@ void primary_expr_failure() { require(NULL != global_token, "hit EOF when expecting primary expression\n"); line_error(); - file_print("Received ", stderr); - file_print(global_token->s, stderr); - file_print(" in primary_expr\n", stderr); + fputs("Received ", stderr); + fputs(global_token->s, stderr); + fputs(" in primary_expr\n", stderr); exit(EXIT_FAILURE); } @@ -578,8 +578,8 @@ void primary_expr_variable() } line_error(); - file_print(s ,stderr); - file_print(" is not a defined symbol\n", stderr); + fputs(s ,stderr); + fputs(" is not a defined symbol\n", stderr); exit(EXIT_FAILURE); } @@ -1148,10 +1148,10 @@ void collect_local() { if(NULL != break_target_func) { - file_print("Local variable initialized inside of loop in file: ", stderr); + fputs("Local variable initialized inside of loop in file: ", stderr); line_error(); - file_print("\nMove the variable outside of the loop to resolve\n", stderr); - file_print("Otherwise the binary will segfault while running\n", stderr); + fputs("\nMove the variable outside of the loop to resolve\n", stderr); + fputs("Otherwise the binary will segfault while running\n", stderr); exit(EXIT_FAILURE); } struct type* type_size = type_name(); @@ -1523,7 +1523,7 @@ void process_break() if(NULL == break_target_head) { line_error(); - file_print("Not inside of a loop or case statement\n", stderr); + fputs("Not inside of a loop or case statement\n", stderr); exit(EXIT_FAILURE); } struct token_list* i = function->locals; @@ -1560,7 +1560,7 @@ void process_contine() if(NULL == continue_target_head) { line_error(); - file_print("Not inside of a loop\n", stderr); + fputs("Not inside of a loop\n", stderr); exit(EXIT_FAILURE); } global_token = global_token->next; @@ -1944,9 +1944,9 @@ new_type: else { line_error(); - file_print("Received ", stderr); - file_print(global_token->s, stderr); - file_print(" in program\n", stderr); + fputs("Received ", stderr); + fputs(global_token->s, stderr); + fputs(" in program\n", stderr); exit(EXIT_FAILURE); } @@ -1956,9 +1956,9 @@ new_type: else { line_error(); - file_print("Received ", stderr); - file_print(global_token->s, stderr); - file_print(" in program\n", stderr); + fputs("Received ", stderr); + fputs(global_token->s, stderr); + fputs(" in program\n", stderr); exit(EXIT_FAILURE); } } @@ -1970,7 +1970,7 @@ void recursive_output(struct token_list* head, FILE* out) struct token_list* i = reverse_list(head); while(NULL != i) { - file_print(i->s, out); + fputs(i->s, out); i = i->next; } } @@ -1979,8 +1979,8 @@ void output_tokens(struct token_list *i, FILE* out) { while(NULL != i) { - file_print(i->s, out); - file_print(" ", out); + fputs(i->s, out); + fputs(" ", out); i = i->next; } } diff --git a/cc_macro.c b/cc_macro.c index f23f6c1..a652791 100644 --- a/cc_macro.c +++ b/cc_macro.c @@ -443,7 +443,7 @@ void macro_directive() if(NULL == conditional_inclusion_top) { line_error_token(macro_token); - file_print("unexpected #endif\n", stderr); + fputs("unexpected #endif\n", stderr); exit(EXIT_FAILURE); } @@ -508,10 +508,10 @@ void preprocess() if('\n' != macro_token->s[0]) { line_error_token(macro_token); - file_print("newline expected at end of macro directive\n", stderr); - file_print("found: '", stderr); - file_print(macro_token->s, stderr); - file_print("'\n", stderr); + fputs("newline expected at end of macro directive\n", stderr); + fputs("found: '", stderr); + fputs(macro_token->s, stderr); + fputs("'\n", stderr); exit(EXIT_FAILURE); } } diff --git a/cc_strings.c b/cc_strings.c index 15498d6..49c9399 100644 --- a/cc_strings.c +++ b/cc_strings.c @@ -39,7 +39,7 @@ int hexify(int c, int high) if(0 > i) { - file_print("Tried to print non-hex number\n", stderr); + fputs("Tried to print non-hex number\n", stderr); exit(EXIT_FAILURE); } @@ -95,9 +95,9 @@ int escape_lookup(char* c) else if(c[1] == '\'') return 39; else if(c[1] == '\\') return 92; - file_print("Unknown escape received: ", stderr); - file_print(c, stderr); - file_print(" Unable to process\n", stderr); + fputs("Unknown escape received: ", stderr); + fputs(c, stderr); + fputs(" Unable to process\n", stderr); exit(EXIT_FAILURE); } diff --git a/cc_types.c b/cc_types.c index f94191b..f0d22b3 100644 --- a/cc_types.c +++ b/cc_types.c @@ -141,13 +141,13 @@ struct type* lookup_member(struct type* parent, char* name) if(match(i->name, name)) return i; } - file_print("ERROR in lookup_member ", stderr); - file_print(parent->name, stderr); - file_print("->", stderr); - file_print(global_token->s, stderr); - file_print(" does not exist\n", stderr); + fputs("ERROR in lookup_member ", stderr); + fputs(parent->name, stderr); + fputs("->", stderr); + fputs(global_token->s, stderr); + fputs(" does not exist\n", stderr); line_error(); - file_print("\n", stderr); + fputs("\n", stderr); exit(EXIT_FAILURE); } @@ -177,7 +177,7 @@ struct type* build_member(struct type* last, int offset) i->size = member_type->type->size * numerate_string(global_token->s); if(0 == i->size) { - file_print("Struct only supports [num] form\n", stderr); + fputs("Struct only supports [num] form\n", stderr); exit(EXIT_FAILURE); } global_token = global_token->next; @@ -277,9 +277,9 @@ struct type* type_name() ret = lookup_type(global_token->s, global_types); if(NULL == ret) { - file_print("Unknown type ", stderr); - file_print(global_token->s, stderr); - file_print("\n", stderr); + fputs("Unknown type ", stderr); + fputs(global_token->s, stderr); + fputs("\n", stderr); line_error(); exit(EXIT_FAILURE); } diff --git a/functions/file_print.c b/functions/file_print.c deleted file mode 100644 index f6c9d0f..0000000 --- a/functions/file_print.c +++ /dev/null @@ -1,27 +0,0 @@ -/* Copyright (C) 2016 Jeremiah Orians - * This file is part of M2-Planet. - * - * M2-Planet is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * M2-Planet is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with M2-Planet. If not, see . - */ -#include -// void fputc(char s, FILE* f); - -void file_print(char* s, FILE* f) -{ - while(0 != s[0]) - { - fputc(s[0], f); - s = s + 1; - } -} diff --git a/functions/number_pack.c b/functions/number_pack.c index d5b1143..03517d3 100644 --- a/functions/number_pack.c +++ b/functions/number_pack.c @@ -20,7 +20,6 @@ #include // void* calloc(int count, int size); int hex2char(int c); -void file_print(char* s, FILE* f); void require(int bool, char* error); char* number_to_hex(int a, int bytes) @@ -29,7 +28,7 @@ char* number_to_hex(int a, int bytes) char* result = calloc(1 + (bytes << 1), sizeof(char)); if(NULL == result) { - file_print("calloc failed in number_to_hex\n", stderr); + fputs("calloc failed in number_to_hex\n", stderr); exit(EXIT_FAILURE); } int i = 0; diff --git a/functions/numerate_number.c b/functions/numerate_number.c index fc7d5e8..30289d2 100644 --- a/functions/numerate_number.c +++ b/functions/numerate_number.c @@ -24,7 +24,6 @@ #define FALSE 0 //CONSTANT FALSE 0 int in_set(int c, char* s); -void file_print(char* s, FILE* f); char* numerate_number(int a) @@ -32,7 +31,7 @@ char* numerate_number(int a) char* result = calloc(16, sizeof(char)); if(NULL == result) { - file_print("calloc failed in numerate_number\n", stderr); + fputs("calloc failed in numerate_number\n", stderr); exit(EXIT_FAILURE); } int i = 0; diff --git a/functions/require.c b/functions/require.c index ba5983c..c16f8f9 100644 --- a/functions/require.c +++ b/functions/require.c @@ -19,13 +19,11 @@ #include #include -void file_print(char* s, FILE* f); - void require(int bool, char* error) { if(!bool) { - file_print(error, stderr); + fputs(error, stderr); exit(EXIT_FAILURE); } } diff --git a/makefile b/makefile index 0710a2e..195a861 100644 --- a/makefile +++ b/makefile @@ -30,7 +30,6 @@ M2-Planet: bin results cc.h cc_reader.c cc_strings.c cc_types.c cc_core.c cc.c c functions/match.c \ functions/in_set.c \ functions/numerate_number.c \ - functions/file_print.c \ functions/number_pack.c \ functions/string.c \ functions/require.c \ @@ -50,7 +49,6 @@ M2-minimal: bin results cc.h cc_reader.c cc_strings.c cc_types.c cc_core.c cc-mi functions/match.c \ functions/in_set.c \ functions/numerate_number.c \ - functions/file_print.c \ functions/number_pack.c \ functions/string.c \ functions/require.c \ diff --git a/test/test.answers b/test/test.answers index 6e33e0d..0254f6f 100644 --- a/test/test.answers +++ b/test/test.answers @@ -4,183 +4,183 @@ b4dfdb3f7cef6571968fadd3e586a19226a546b3d470cafb8b7c556e1d2d3bfd test/results/test0000-knight-native-binary 235cb8354a6f890c029b61d3371db6c539d22a8fedfc555f171a742def20e1a9 test/results/test0000-knight-posix-binary be8111d178501a86934f10de64f815e6812c5ee31ca31eb5a0e51cdabae5ad14 test/results/test0000-x86-binary -70940a7dc3853703f6c4d37dfeb7c7dc9002df744aefacf8af672138b89a0f11 test/results/test0001-aarch64-binary -733e937c3f593d2fd8d56952dabd646e833af2a69989d8569d76d6cc822ae175 test/results/test0001-amd64-binary -8e323606f695dc63218b2d1201862d200dd5e637d5b7642ddf511879f739884d test/results/test0001-armv7l-binary -4351d8e0d6926a57998f27e57fb792a46d08378329ececd1b5c25f65e394bcab test/results/test0001-knight-native-binary -723404430c85ac7854faf790f650024725aabd7ee29c8d5bc6f5ce7e3c4a896a test/results/test0001-knight-posix-binary -e0abcc07d984e91ceaac468d772ec223c95e621fb0c8954ad6ade372c8e87841 test/results/test0001-x86-binary -8f75e029edd4965295634f6c9a6c862efa422d7e13aad255e3290f28d5f17616 test/results/test0002-aarch64-binary -9907399589419a35186b6ffe0cf89cf5f06c06280dec526bdb6bb5ffdd1a7da0 test/results/test0002-amd64-binary -fa7724f7c89d930c6a6882ac72f21b17d387483c8c5ccb820ad10cde3cfee2b0 test/results/test0002-armv7l-binary -73efe718c185895a679588146f3968e1dbe29ad88d443ce8d2c06cbe72e9a115 test/results/test0002-knight-native-binary -be0932ed7f9798d5da215406bb95495e0d6c2712ccee4f1fd4a7b49f3c1bb307 test/results/test0002-knight-posix-binary -4f75e60e0e179cda6d25649907427f1113bf3793eae845cdf7aa5d89b85a0a7d test/results/test0002-x86-binary -6eb47a047190549a175bd3aa4f9385698bb6c378e314ababc5a58bc1f6325755 test/results/test0003-aarch64-binary -dace615925d034211ebbcede0062fc865ab9b21a7d1cc100ac6e469dbca59704 test/results/test0003-amd64-binary -109956fcdbecf9276b2372c5930714181dedec05cf8b5330eadc7ca7197c75f5 test/results/test0003-armv7l-binary -8bf596e3ad29a498977d24524c01c0150a74a1951ef9aa576333c6727b9e40a0 test/results/test0003-knight-native-binary -c7fe7dc508bd9fa756e774910b9f36f1ff87c7e18d36b611737f60786452a0a5 test/results/test0003-knight-posix-binary -d002f4676b95d40ff2a7830865e7f160eeec9da9494d2619d65bdb6abefa9323 test/results/test0003-x86-binary -9e6a723153f5c3c3011d9fcd46e6b45bc204d238215e0a9b280c069e86e8c85f test/results/test0004-aarch64-binary -3dbfeccf26afbae9c6bcf07c2f27ea6dcb95719791b6929d4131e8cdaddf6b6f test/results/test0004-amd64-binary -1fd4eeaf912977608de9db81fa577b76bb1c92c70dc3519c078eb6300e2c8a47 test/results/test0004-armv7l-binary -4c29ad76dfeca017c158ce6c42274ddd8ccff68bea869d7a0606a8bd641502c6 test/results/test0004-knight-native-binary -37bc3ca886ac34006709bd871bfaa54338f36364f6bf0c18e7e14eada852dc1e test/results/test0004-knight-posix-binary -e09e9e35788a89cda02c055f4310e584a2392c94b18b70fb1ddef396d34f5c20 test/results/test0004-x86-binary -e6316ce06b96801730bef9ce11e2082d8b23654e9a087fd31052a29d9c890fa9 test/results/test0005-aarch64-binary -3d4dee12eb2df66da89ea5ba35f07a15c45ca4dfc39d8a131b0ec49783c30d15 test/results/test0005-amd64-binary -8cee486136ddf7182620052f79fa1090c24fcfe67c16af859ac185c9669ba9ce test/results/test0005-armv7l-binary -d2a0842404f7b56795ccd84df8d874ba2bfcf592a37475b46cee4e14de930d5c test/results/test0005-knight-native-binary -0d404078a4d834d400eaae3641616f3ef1322c09484386b295befdc574e55f7d test/results/test0005-knight-posix-binary -7ddd1e83e568a5d84e01abc6101d668040cb412c2fb9aaeba478bbe9d2f00bca test/results/test0005-x86-binary -9962ce5d8d670054ef39dfa32bbdb9bf0d2724746624712ca35ffb942ce97393 test/results/test0006-aarch64-binary -b906ccdf7246d53107246c51ff59433254822d84167470cd17da17e87f37213b test/results/test0006-amd64-binary -7a87589e3e2916a1f3dbb908e5c43b80bec6706c79bb4dddc3d69d6a9adfed82 test/results/test0006-armv7l-binary -877ca3221bea8b0fe6182539fb53abaf7497e9a4ba6b6bb888ba9b7df9d55264 test/results/test0006-knight-native-binary -ed80d39f5953fcafc4eb642a9134334ed45ca6b9cb9faeef62c6ac052c2e14cc test/results/test0006-knight-posix-binary -fe8ceff807248c6b1896fe34696a39ba8064660b8d619242e51312ae312c619f test/results/test0006-x86-binary -c9ecc3aba1b2695c14d96c9138fd305c012e68fd66f77c3c9de783869f88e199 test/results/test0007-aarch64-binary -aceda83d406a6f1814310c22cca1944204f2f3d8125c5d9e73f0807e5a87475a test/results/test0007-amd64-binary -34d3a915fcf4f9cee47ce59de134c826adcdedc44288803320a73df284d7dd15 test/results/test0007-armv7l-binary -37ffab9ba78707d5a19cdd172f49502cd53e47e3b447fbe7368ffa71178ef434 test/results/test0007-knight-native-binary -f04bbe450f02f3a81bb835b99bbd1a4298f05f5f8ed1cd93a6a330bce24ccf27 test/results/test0007-knight-posix-binary -48c320b8899dff3f9b29eb1947e56982024a687bdb89ca519522383da36b97ec test/results/test0007-x86-binary -00ee4d7fe3573ec5d92f9cd6220583531c6bde8252ee5f94f5e9e55b71e05eae test/results/test0008-aarch64-binary -e74989505bf4275a0f340bf0ac68db1ae56faad6e69763532e762afa747fbba8 test/results/test0008-amd64-binary -e7861e62edea246ab0be329730b61e43699b6ebe28ec4fd54561ef2d025a68d8 test/results/test0008-armv7l-binary -ada6a52810fdedff421878b59740a972fcfe734b80b8c3662e0759f118805d74 test/results/test0008-knight-native-binary -be3090bbfbda6a759a3fae6389cf8885cc0ff62393eb46ec251b88e5c86679f3 test/results/test0008-knight-posix-binary -f93bf6566d685c7e21eacc2f0b3dbaa588b0a4540a3671e40f18435cce2d80cc test/results/test0008-x86-binary -78d141be9b1dad67ff624c5b19f16bd74a82664ce3c894fd0a77868eadac19ce test/results/test0009-aarch64-binary -dfaf11cd8a46d37f4c2e97ad3b1929252c038df5d6e7c7ac2587b8a42874cf30 test/results/test0009-amd64-binary -1358e314a7c675e3a6d4f3767ebdee7aa31f5ee6ba4f275dc6bb6a319ad72bc4 test/results/test0009-armv7l-binary -ceabd6f4c7901fb52d504fada31142f83b006af7a207cb98a5631a662592ee24 test/results/test0009-knight-native-binary -2476852ca2525c42cf0d9f94df0c3b5ed0a1a135a371eaa238296cb555ac6ab7 test/results/test0009-knight-posix-binary -b3eeb7e341006713a42bdf47ddcc820c05d674cdd6ea626e5a7b96eedb1f5f71 test/results/test0009-x86-binary -fa7c8104bc75fa7316aa6be8b687c893dc94d8c4ca27f62dd8e689c7ec2cfc41 test/results/test0010-aarch64-binary -5871b8fbbf8e22b00af41999506e004ecd48765d304373248a3590370c23a494 test/results/test0010-amd64-binary -5b6855aa171b9ec4341b55c7d83237bceeeacbfd79bb7636c2708c85495a7f2c test/results/test0010-armv7l-binary -8af5b1bee7b2228cefe7befed42191676960925ce547cd0c8a9464f9d7b68159 test/results/test0010-knight-native-binary -ee426561aa1a5aabd95062c541a6568573fc8903b9dfc65605b0b7b4778f1e24 test/results/test0010-knight-posix-binary -e4ef6b4b6fdf99e9468542c23d3016c7673402e71499281fe8f92080308ab7ef test/results/test0010-x86-binary -751cff542010e284e12f37623bee534db84103841852bf25d8eb0a30055e1a04 test/results/test0011-aarch64-binary -b660d0e151871273aa6fc274f996f74294314102cde0917815ce9cc60d3f3c89 test/results/test0011-amd64-binary -7a5e4f023bd693e7f20b2067a43926b1ff985912356915da9d3feeaede4ca723 test/results/test0011-armv7l-binary -6453b4f94e6eaaf4ed182903bb1dcdc6bf1755bc945cdd79001254f1ba36571d test/results/test0011-knight-native-binary -c4611e2bac36e7cbb47cf3754c2266169b7003347f51b0f62cb9f54a871293a4 test/results/test0011-knight-posix-binary -48900cb9da31467ccfd0fd5bfd57cbdf5aaff35a2d143c142da9512135681b26 test/results/test0011-x86-binary -3d3e1175cebbd24ba6b214f4f206c7888734dedb2038131b6c9f566f91f82b04 test/results/test0012-aarch64-binary -55ff41ca07ff6f5578455f109923d6ba0f5e9839e25c43d019834b0f18c19df7 test/results/test0012-amd64-binary -f536701cb304beb791ded812b91e9e844e8acb865be7b2d2190643b043c49572 test/results/test0012-armv7l-binary -0fad030caf14182c3568579789fa0d6dc0f926db9adf6957184bcbf06a744a43 test/results/test0012-knight-native-binary -5505d7ab9176e5cd903def96645b3fc3cda90d8f3f7aec3dac9b126097e3712a test/results/test0012-knight-posix-binary -b10b13abb0a7df5e83288a31e097237083e4be56fcd52d7d219cef5b7b6931da test/results/test0012-x86-binary -f4482fddc5c302fc72e2e04e78f492d902d8aef7e18d48d404b5e100290fb98e test/results/test0013-aarch64-binary -0a5b8d8d5d7e7fe3d383fb8a7b5c61f882d7168c86eb5e1cf91c921817d4dccb test/results/test0013-amd64-binary -6bf474ee33b635ec9b17d6027f7fe4d65895d6afc56b5c333d4ed4b3caa0f0e8 test/results/test0013-armv7l-binary -234d69d9c80bad42e2642a8e5da3f6b01261cb1ee1abd8c53ae626b7eaa70ac7 test/results/test0013-knight-native-binary -f76b9de4aba5cbef1b242af430f94a69e0cbfeee1c3428bd95b874d0c6d70487 test/results/test0013-knight-posix-binary -7dd6a9a103c7829e92c3dfa847c14ea7de4a9f3068b6a951b131a743fec2ed28 test/results/test0013-x86-binary -c35517de032eff7b5bd617a90f96315ca0aa6afef9abb5a03490af402fce8c80 test/results/test0014-aarch64-binary -1dd8667124c5f74358613778d38ff5bc8c657d1b3eba1bb1a95c13668f931ec5 test/results/test0014-amd64-binary -4e5b9873c54d00a93508e67e0bfd28da63f4ef54d0fe77a8a0935b82cbb91325 test/results/test0014-armv7l-binary -ed4b4679d2122183ab3dd6e8b587d0215062b72955d5b742a264024981e75b1e test/results/test0014-knight-posix-binary -a2c27a2eed021f1f9398d4d84ef7a405eeca0f99311498041d6c16c0305e7283 test/results/test0014-x86-binary -873f55f8ed753f556b6e75952088f496ad6f989b93fd27df74b5bc87925458f8 test/results/test0015-aarch64-binary -f0ff48edf38314dd6f1806ece58bfc068362ff8a6d61867d94811268e776c7bf test/results/test0015-amd64-binary -37be22a3b1384d00346fbdabbb89f14400a7979a03c65188224773e84fc3f717 test/results/test0015-armv7l-binary -7538b7a37977a20e8364098782849c33286e04dd363066ddf01c560d2c2cf478 test/results/test0015-knight-posix-binary -713305539417921a76bc9a8e37964ca33e761cbb4704b17d7bf54585b554987f test/results/test0015-x86-binary -1e7ce0ef566522c0654f336ac4aec444f1e85a00968e6a2c51272db8d475212b test/results/test0016-aarch64-binary -8fc71c2934dbe82185479a01a2ebb9f03cf7212b71f7dfc5467fe39bd2da0a75 test/results/test0016-amd64-binary -5cb0cd38a0baa627d9197b9b2f65ecaa50f96dfb23db1c7854a6f0ccf9965861 test/results/test0016-armv7l-binary -47f3794eb53e7a66cabf72b6a7c7366d2e0cff2fe610976fcc5deb506bb391c3 test/results/test0016-knight-posix-binary -f89f7d64b2f24ce86e287911e282893822c7b1cd8bcbfa7ea28d4c118d2e7d45 test/results/test0016-x86-binary -8f74d3969604c380105ae05ab4cf750a9091bf99ab10b6d9a0fada10598f7ce1 test/results/test0017-aarch64-binary -6c6dca0d45f7a641f17a1dc58d28e2c8f1c4b92e718e4fcb0f47fd082335bd39 test/results/test0017-amd64-binary -e2d4938f7b4d58f4ba2bc2888ddc23cb9f868216d6881e275d07d0c4cd04cf45 test/results/test0017-armv7l-binary -8dcbb0461b173a3837526a51eaa6dd737ae967f90e1bbad70d01e813e045aca3 test/results/test0017-knight-native-binary -4c89e85b2b100c0d3bab20c12db6adee57094ba0db22bd96d27dda00b49cab40 test/results/test0017-knight-posix-binary -62bd30b76ba0f332ff0a7ea2f6765137d753ff2059558a0214324b02322fd783 test/results/test0017-x86-binary -e921aec2177de81074557d03b7ea951c05c4479bee0d07c178dcfe26c08c1988 test/results/test0018-aarch64-binary -e38158165f975ca187b51b3822583f7a2c01bec8da5662050862871c158ac2df test/results/test0018-amd64-binary -a26d23b12d0296590f26c396c8baab2d9190bb7215eb59fe66ae53a588b425c8 test/results/test0018-armv7l-binary -b66191b86e77dab31307d822ac9e72df0e544fd0dd79935bb38e751e117fa2db test/results/test0018-knight-native-binary -c21bf8c43022cba8552f2dc457c5a3f18e386227315c6360291889b920a0ae78 test/results/test0018-knight-posix-binary -b2b82567501d3359fe34388434205525a32867cadde52ce67c485c1696b586ec test/results/test0018-x86-binary -912e2a5b83ea590da9bb47578f699b4db8849cd0aed97bf619588a6f9f750c97 test/results/test0019-aarch64-binary -494388c7c9f92ab8669e042f6f860d1f0b245b4892d7095609956784760b39d1 test/results/test0019-amd64-binary -6a49aa52916fd19285514500fbeb87a33c6bd9ab12c79280a1a7092ae5df60f5 test/results/test0019-armv7l-binary -f63f4826dfc7f14593857bcb265fe26c7491dd574bdd90c35b543c35bbc32306 test/results/test0019-knight-posix-binary -678ce923e98b386cd02c6aeb5c2c00c02ef0db1b9828bcd6986628c752f9726b test/results/test0019-x86-binary -2806138df8f32c5b9d0948b79ccf6c36e810e267c562895ecb35e3d7715c7f89 test/results/test0020-aarch64-binary -e1504b22e5a70d7e22c1fb43044b56d02b6b9ec8a4dd4e1089fee0c4b7d0e45d test/results/test0020-amd64-binary -2d7594233a0537ee923f7465d36f808bff61e69e08b10bce7e2b399b72951496 test/results/test0020-armv7l-binary -36b27934dbf02a43ea8ca7951ac351fc972d7539bd4fa7f9fc4145192ca08f89 test/results/test0020-knight-native-binary -bc0f6705971b95cca0ff7e7c5121c344feab0c912cf5a9f0f56420b54ecdc375 test/results/test0020-knight-posix-binary -249e01b6f3834c1dc4a056a0b88d65bfd805e0e0f130a7a5c7e1bfba5c4bda0c test/results/test0020-x86-binary -4e564856741f7aecbe199d7cb071a926a7ac085a3eda617c8518615a1d82b280 test/results/test0021-aarch64-binary -7da41c4e28ffe01d701e09ae36e397d826474197e8e67ba4ed2cf0bbbb448b9d test/results/test0021-amd64-binary -dc92402a6e26327ffa71b996451041f43d559e7c8b1bf8ca9a75f33a6f0c57b8 test/results/test0021-armv7l-binary -ce7c14a3a49ec77c478b27619a9e8982e3c2db63876fb0b17f25d3ee0ac769c7 test/results/test0021-knight-posix-binary -edf11e3a4765c6bd221c3de3fc52de9716f5f8f4a2621471fba90ee544ca0ad4 test/results/test0021-x86-binary -f9cdf59df2bde0d727a06934d62b484914f908b8802f3172cce4250528d605b6 test/results/test0022-aarch64-binary -338d87ca92a12115b55c3236904dc71af8f2c6e0c0e9a5dcd1e78ba0875e6b11 test/results/test0022-amd64-binary -b85c6c9da84d16b95d87c6512c50271dc620405fb1296c445f5db5b1bf40731d test/results/test0022-armv7l-binary -a788540200fef560782604593e597334917d844b087f624a9fa10ecba5d3c6c8 test/results/test0022-knight-posix-binary -4d49b051b7628f549ea5c1b38e97985d63b66cb8170283270a9a514bb612cd19 test/results/test0022-x86-binary -eb27c78015231d48b048d972c697bee09a4c53372c26590b3acf8138d5c742e8 test/results/test0023-aarch64-binary -a6bab8bfc70defb472b6492735d1984a2c940ef739a74ac9ccd8d184be2a8a5c test/results/test0023-amd64-binary -95326ca2ad87df335e39af71ef1bb7616b3c300f7fe1905b92963d191f9dff5f test/results/test0023-armv7l-binary -324e1d078170413ff9b5cfbf86ad0e6ab7ee26273a3493bda5b3d00bb70409a1 test/results/test0023-knight-posix-binary -23a63cf104e71f3b7967fdb8220d4eed3676cf2f1d22c0169c5ce6d28ffeb540 test/results/test0023-x86-binary +5465950e0f8c1b5994ee29c9a32e404a66b6655af016190629d5f0fd6a6de12c test/results/test0001-aarch64-binary +67be47e6f5f99a0ff629ac5e6ad3eeb53c13e4c76568aed9ea4428974a847468 test/results/test0001-amd64-binary +8ec9f0eadce186172d9fd7a87cc7b5bc71c2e9a305e1063473fcfac85a8b02cf test/results/test0001-armv7l-binary +12e7cdbab3bae4f1668743d31e8b47ed1c7d3f58fafa20a83a0f63617e701131 test/results/test0001-knight-native-binary +e54950844789a2ac6e08897f85f17afca52aab6846baceaf7b8d791ef57697da test/results/test0001-knight-posix-binary +3904e53deefa882c18b4f4db89c6871c071d4417f373ecb116cc476cd46bf106 test/results/test0001-x86-binary +2682923625cab080f720240573dacdf8a7739556433a4333b0e474ee2f82f1c2 test/results/test0002-aarch64-binary +424a1a835e99e707adf15ca6e1aba0eb46cef69f37643f97402c1062ca23c902 test/results/test0002-amd64-binary +74cb17908b38b4be2187302e7a45ce301903f84a3b3fafac5ce1d9be08c15e66 test/results/test0002-armv7l-binary +de15c5b20dba2d102344fa560ba3fa8af2357f6feeabb31834af31a0210589f1 test/results/test0002-knight-native-binary +7598b6314ade3f96059b2ef72616b74b96044223cdb088de1b3dd27c6acbeb91 test/results/test0002-knight-posix-binary +7b81d716ef5d62c331a379f979bfac7f57f8e5ea22d32dc26d7c8d5ce7d875a5 test/results/test0002-x86-binary +cf4620346ff549b3be4168dc4579d9cc86cc3dd582e817a7a14a910584b2a14e test/results/test0003-aarch64-binary +570bed53b79a7c6d6c9044365659a0361a04299ccaa5a1c7895fc4484d809688 test/results/test0003-amd64-binary +afe29443154a0273862d8358dc2dbb54e86929152eba5f004acce1079368b0ff test/results/test0003-armv7l-binary +5ade38205edc814dc6e211bacdc65712ffb3370f07b487e476e054cf1ca56a18 test/results/test0003-knight-native-binary +7ba3d24161bd185530713b25387c0200972d782185db00c1b8855a39f831eb61 test/results/test0003-knight-posix-binary +d65f4901f6cd0769b91635d9002120d4f3695d24f50ac7a78191aa3a1bcb87e1 test/results/test0003-x86-binary +29c4ae8fb204fdb6d98c60b6b9c512b5721bdf786d9296f0eaeb21755b5de29f test/results/test0004-aarch64-binary +7b454e935975da468dd4cd66d48d6ebe84c74c917a6bb5c074bf5546047c4c25 test/results/test0004-amd64-binary +ca3c72bfbe22498535f591b5e37e93feda1f1a27ce871c189564530d5a38d0ec test/results/test0004-armv7l-binary +c655777ffe03138237c6fedeba6b68b3c53309835ed7a33d6853e8c17003b1f0 test/results/test0004-knight-native-binary +357966f525c925fa604aa427c6fa7eb2d2b39388394f8b35157f63a31ee75053 test/results/test0004-knight-posix-binary +a2b19814b0a99196ce9091a14115f274463751a8eef10c3d5593e7ebb61b8e8c test/results/test0004-x86-binary +38542a6415f1cb828db9b9b9468acdc93dc837715b97d945868ec1260fdd39b0 test/results/test0005-aarch64-binary +cb84e820ff24523b1e8d49e70446e014f465284934d53a97230176999e0c4a35 test/results/test0005-amd64-binary +20c2d8ab361168e69fba7d03a75095cd92c4e1c51745bb6d334bb5f666b8ea40 test/results/test0005-armv7l-binary +3107fc5b5bb9effe0606db09cd85d271af838c24166065f7454ee8b2f8d76965 test/results/test0005-knight-native-binary +5bdf81c6160725746872a3e9fbf51e25da6d74baa8379d5aa62162263adbbfef test/results/test0005-knight-posix-binary +080332a0e8081cf69da59b2d47f9d27e792d0ba05d0eb89110aa07f66fffc47f test/results/test0005-x86-binary +42399dea34c9ecb0c68c1b8f0f607b1b5385da1b62b3afb3e718b0547852df28 test/results/test0006-aarch64-binary +287b3a16a312f69273c3b11b0f7858040152bd776dcc2fa0f0cfb834bda0506a test/results/test0006-amd64-binary +e9ada531a1619835e5a0910d563b18b9d629220f6b1f9710eae606749a198faa test/results/test0006-armv7l-binary +bdf00083589f1849a572c2a7d3bdfc9130efb11f98e59eb143da8f6a360ed450 test/results/test0006-knight-native-binary +11f746092fded6dc0ffa2da38b993e66c646db6d91d2999e9cbd4dae1523a8c1 test/results/test0006-knight-posix-binary +e7ce65dde114b4ffe1b8f1a6fea0c9e862a15d543bddc228d6bf8b636b304136 test/results/test0006-x86-binary +0a30453f4ec0dcd5667d2cd44cd4dd36f0bd3a8ce18f489eea06f8040744f464 test/results/test0007-aarch64-binary +53b1e3086b6cf15f5f2bd06d8cd99e69539582ded6de93d9887fdc228314a3c2 test/results/test0007-amd64-binary +b03747a50d68ed0c86aa0f0ae75e44fc6528402d165f53f671c70484c26fd9d2 test/results/test0007-armv7l-binary +cafdc2dc7b84fb06eda25742de2823e8c39f8d212adacf28fa6b00febdc3fd01 test/results/test0007-knight-native-binary +85a3bffe2e426316cdbd593740ddf6087e9194551a9c58f25a91c91ef9fe9100 test/results/test0007-knight-posix-binary +06ef72912a35fb91aa536ed2d1d989d69dbc583438a1516b495cb215a3d5703f test/results/test0007-x86-binary +f1f099b7a3d87682710665f54e2dcf529b0572044bf8ee1affde041e1adc29ff test/results/test0008-aarch64-binary +a010f55347f3cffa438d620f86a6452347b2bb25dfc810d8675cc2a2016f9700 test/results/test0008-amd64-binary +69ade0a8725a0e4184975d1ba509393cd9f4cd8681ab9012ecbce5cd4f78b803 test/results/test0008-armv7l-binary +1a5cde8be8dac11e1b021687a1215da8d82ea498858b4c8aaea7ec342198fc75 test/results/test0008-knight-native-binary +b27128efdcb017d579f6ea9387112007f8c694cbe9450dc63a85370f64be7b05 test/results/test0008-knight-posix-binary +a700cd5a3d54f2a97302934bcd3e10d13b9f00980ad048834a419d313f4c7a86 test/results/test0008-x86-binary +5eed9694849df6201cc5295812358b371dd57a26f561ea1ffe3b85edb99ae682 test/results/test0009-aarch64-binary +c1b49886dea195029efa974690f4a6b57f323fde42cf8231fd99f44577bed13b test/results/test0009-amd64-binary +bdc4b0e4964dfcc83f9e138e538dbadb73f16d79769bd8f59830401ef42c6c77 test/results/test0009-armv7l-binary +7a7765231989d78d6c722d9f0c51250d3858d36034ef491395651cd76841d7a5 test/results/test0009-knight-native-binary +26959f161763c49e2434e4a779d95e04e4a6112faec32dee4b96c82905af4efe test/results/test0009-knight-posix-binary +2ab751dbb85677a6155a1cb93312b78fd30ac25f6bf35af6016ffb5cca24796e test/results/test0009-x86-binary +f00a04163c7f6fc076da1e81d9ed301531055ee435c8bf9a01ff2cf07c0e5fb0 test/results/test0010-aarch64-binary +fed713ed3c7b7d0a4ddfe9608213a82b137ee814f46ed52aa52bb2b7541f84a7 test/results/test0010-amd64-binary +a00d49ef729c040d6dad792bb98202e98016ba7bb39a745728ad502fc599f630 test/results/test0010-armv7l-binary +d935dabeea99dcc5e40de6cd2fd79145a35eef997be39888509559f803b602a4 test/results/test0010-knight-native-binary +b8558af950721117592cf6458816774684e0a492f920d19e8a61824ff3eb3f7b test/results/test0010-knight-posix-binary +c0b1b346d2366d266c771022ac30b39bf96312d3361e4b13e196127295ad38fc test/results/test0010-x86-binary +3dbc248e61c23ecedc395a60a670fb325176721e1d8ad3b912eb249ebad6e2e7 test/results/test0011-aarch64-binary +551ac00f402eee592d613aa5b98f5d7926d4c51a5434e183ee587034be23e4a6 test/results/test0011-amd64-binary +768e0d0e3c65040548a16bf7dd6b472f6e1a40d07e3092325a368a6c50c13b07 test/results/test0011-armv7l-binary +fc6b7aa8d1bb5aacc3ec36f5173138687804d2c73041b4bba0752a5c888e85c5 test/results/test0011-knight-native-binary +7c3c953a8b35b9270e5724fd567c8306dcec84223802190ffc1ddd47f9793d54 test/results/test0011-knight-posix-binary +5f1f4f776fa5ae9b03c0c537c6e3758966dee37b32c820ba9bfd6debe09c2b36 test/results/test0011-x86-binary +00a47caa202ef2c990ba4053233ef1b20ba46ba32e5de287ddec731289f78ecc test/results/test0012-aarch64-binary +232c9d33400c20a40d7d4af5b7a87859385bd517bed87d641f68069ba89001f5 test/results/test0012-amd64-binary +07743cb7d71614e3a0ef11eabf08f369b0ea1bee8a563e3ae8d222a1e1c709cf test/results/test0012-armv7l-binary +04561f823aa06b30b3b2920897cef10f04e874410aa96555a32d909fc64f0e94 test/results/test0012-knight-native-binary +e8c1498241ca623628d9d2a237fd9e080474d94a50e1375010ab788f30907838 test/results/test0012-knight-posix-binary +7993de808fddd7d4cd981484cc314fdc69908600daf72c9d0778feb30947c50b test/results/test0012-x86-binary +0c85bbf470fe8baef37ac256f6a04e09b343a6be613757065333a3e3b3a322d2 test/results/test0013-aarch64-binary +143b2a1057d9ea7c17b71795bf4b4e83b7a368c35216e2b3fd4134b0cc00e290 test/results/test0013-amd64-binary +21d099c9860f5b00e622904fc6c375683c694d1cf67d29c2f8073b7fca7ef794 test/results/test0013-armv7l-binary +1480209eb4f1849b168d9af49fb050e25b7c82ad5e1b8e502d4b23b88bc8552d test/results/test0013-knight-native-binary +77b21c9ab47383bdcbb9f58d6e3ca1394b9b0bd8f3b833c181948ae08fbde8eb test/results/test0013-knight-posix-binary +f4402b356b58e7e580679b2607b8d2ac592fc59e212d3684609605d55cbbc8a9 test/results/test0013-x86-binary +a9e30cbe530d7211a55a753584f1d78838095d553caaf0aa66bb3cccee06460b test/results/test0014-aarch64-binary +56d4e9392e7e3fa117856ca9648b041ad8060993489ae25fe13be02b897d0b78 test/results/test0014-amd64-binary +ee09bd37afb94f54f1729c27b0c303286bef27e88480776b7a6050bacf9e738b test/results/test0014-armv7l-binary +27358a04f32cce6d4bef37f18aa877eb884e18bcc91298cdf74827f0ce616710 test/results/test0014-knight-posix-binary +acf4038568c5973a1a12a7f331614e6a8a8236b515e6ea7631d1bc738943996a test/results/test0014-x86-binary +1eb936fb9195f6d15bcd34d636d5dc5d4c6c9cc77dedaa3e83a0f4779e0480a8 test/results/test0015-aarch64-binary +c2d1e44662a9b161045e1e89e08149597eb793d48409908521c4e7df09a1812b test/results/test0015-amd64-binary +0fafd6160c11f0adda22b43d28967084f68b95d88ff9b86b6a288e3fa425a887 test/results/test0015-armv7l-binary +dbe9a50feea76b568da4ea4dfe21a00e1162d0a6b68567e35db51a23e0459799 test/results/test0015-knight-posix-binary +20c4019eb604d7fbee1e26902e6217227b5eb5c836069e5edf18b53e7d643e0e test/results/test0015-x86-binary +7896379b97dad2d149213b8586b406b7bc5c9f060d0cd473620620281729760b test/results/test0016-aarch64-binary +894d8eab846f2387d5db2ca4754a14e1f64de6835dd9c5ae03d444baed7adf1a test/results/test0016-amd64-binary +4080346e54a93c96624602096c55220a03158dc05032b6167fb38adc72798359 test/results/test0016-armv7l-binary +6103a19a3b1fe310b375dcc577b3de8ffcb2ad811491988552d98aff69da4e71 test/results/test0016-knight-posix-binary +48479769522689972f8395209c9b121a10eb6e95ed6344840d849db2bf86c9c4 test/results/test0016-x86-binary +bc4dede8ed93cad23bb24a24329ddfe1e16d99ad6dc9d73a463ce04785b98047 test/results/test0017-aarch64-binary +a4a791706c2e1955d5f88713fca4d2dbe2e45e80f1e99dc637b4ff5e15b59de9 test/results/test0017-amd64-binary +b70998743f7ac87296c69f16999a0cb248c3537f5bcec7181138fd7fe8dd839e test/results/test0017-armv7l-binary +d4944bab7eeeb0f0173110aa35c2f9498098257a22af5f53e59e2ba86a64e78e test/results/test0017-knight-native-binary +2c26123d0791da270f72b96748c19d520e67cb9a92b89584f11f0e2bf8122b7e test/results/test0017-knight-posix-binary +269e988c5a0bb068c4367e7d301b1891a06242441d7dfda8deb7fce2cf60173a test/results/test0017-x86-binary +a7220775ac37c772ac1cbb160484ca14434d8be2d6e23b55b2bd596ac4b9268c test/results/test0018-aarch64-binary +7c075fe81dcab0eb626a21abcbb1821ae9056a26d2b6d1fe9a7805fd4cad3624 test/results/test0018-amd64-binary +dec3a29cbac6f1db3bc88eb06c3ba8e8041cef67582d6e87c9c9192c562f4aa7 test/results/test0018-armv7l-binary +8574c6f226f9cf85dcc60c7cf17cc585dff5a4e33b68f492cf0ef481ccd88bdb test/results/test0018-knight-native-binary +65c080ac9faa024fbc60753b5ae392d1ad02ca73df25f20b914043010ae11fe9 test/results/test0018-knight-posix-binary +ce5f1f72553b68358e0471c60752c13601ab9a105ba2cbf89a02487910e28748 test/results/test0018-x86-binary +1ee8c41a79df0cad1c3726153f20c86af60cf19939f956661d4421074fc4234b test/results/test0019-aarch64-binary +0143e4d23bed51c35c5789545d5fdc6a77cc2f5f334a14df551b30de13995977 test/results/test0019-amd64-binary +e7dac4a88673ebd8aabb94c9a9631e4007dafbbe8e499dab7315afb3f6e8c1a8 test/results/test0019-armv7l-binary +6f888eb277ecfa17b86ce79b5f64e32cc31e411bddb4d1413bf6d2f094b45efa test/results/test0019-knight-posix-binary +07d5280e04d8838666ed64ace909d659ef32156088486c2dfb2636f95e7bfad9 test/results/test0019-x86-binary +4ff4e38663173f5607e71960bc7a80ada870e7f4586aa343d715f4a7ef257d98 test/results/test0020-aarch64-binary +feeaa62b3f02956b0d7cb1f6725c1d85b40c3d60eb9886b1b065e2eae16f7b62 test/results/test0020-amd64-binary +bea69049075b5af491b406eebaa945a9fcdbbf03effa8cea3b0dc5d067817bba test/results/test0020-armv7l-binary +46623b9861de2401f8dbe96d2b96b64e35c62aa6013a2c90a597a65e2551d3d5 test/results/test0020-knight-native-binary +631f66e4cef20e6f628de01d461168e51346ed68b26926970be46bedffdf0391 test/results/test0020-knight-posix-binary +c45a86f05471331aa55e28a314836deb1d33a29966753fb18909d98824dff76c test/results/test0020-x86-binary +ecbf558224926b0533a4a7879d54aab8e6097c56ccd7d9216aa629e6849873bf test/results/test0021-aarch64-binary +fda5e33f4a7604e492ee1cfc5e2ce1fe7feee54eb2602cdb8f4204f2e3758ea5 test/results/test0021-amd64-binary +f867449035132f0dff29a49d5e3d8e68e7746661ea3887b0a6abe7a4be5f5e3a test/results/test0021-armv7l-binary +279925432c13666aa1a752d19727e461d6bb86769cacacc3aabc179948967de7 test/results/test0021-knight-posix-binary +4b42d4e9dc7879726127bba27c0b6efda845ecd6638c8dfb8a7783c12d018830 test/results/test0021-x86-binary +7acc51781155c0f8b06b7b452b25752069be6fc294e776a9e67ef6b52a33133f test/results/test0022-aarch64-binary +6fd6c60a27bf0a22ecf4804b58f9fc531db65943d08c9d27153c8ed06b7d614b test/results/test0022-amd64-binary +bc7a5dd55f333a52596227c857d31fe2e3a782d54892cb240600e695dfc80f89 test/results/test0022-armv7l-binary +a0d9319bc7dbb34a0ba941732eb90352b968e258c40d0468b30b620676a60c88 test/results/test0022-knight-posix-binary +2017fcc515d2968e3e2da798a6cbf1873f952007b362a36fb9c77507300a6cf5 test/results/test0022-x86-binary +0e67f64655cac56d7cc282e52dace97dc64a4b6b7bda7c36c6746305b38c8ffb test/results/test0023-aarch64-binary +ee50559200bc0571bf261a704316a19b97130c45ed88ddf0838a1e58e1526d9b test/results/test0023-amd64-binary +8522885e02104a6fa43fb56181453a22f03fa7a7257544b27ef9ecbea21f2d63 test/results/test0023-armv7l-binary +9bbacfe541d6960ae90180351af00c1b6be4092ac0cd8a77a29b1aacf6a94338 test/results/test0023-knight-posix-binary +8b5d7828c797bbe20348571e1b6ecab78053cdfbb1481f99ef32b8506688d89f test/results/test0023-x86-binary 6073f5fde626e3e9ab2d8ad1c0925f174da8874d6dd60d38a242a902fc622ada test/results/test0024-aarch64-binary 2521e21a521f55751f6e36d7514d375dc6066f96188d70586995747f83d0ce16 test/results/test0024-amd64-binary 868f9c7ddb784912bf562a62c0fe531671c6375ccd6f606099d677661b52664c test/results/test0024-armv7l-binary b4dfdb3f7cef6571968fadd3e586a19226a546b3d470cafb8b7c556e1d2d3bfd test/results/test0024-knight-native-binary 235cb8354a6f890c029b61d3371db6c539d22a8fedfc555f171a742def20e1a9 test/results/test0024-knight-posix-binary be8111d178501a86934f10de64f815e6812c5ee31ca31eb5a0e51cdabae5ad14 test/results/test0024-x86-binary -179bd9d15b0ab033d7b339a3375105bb0d1189d2029a44074c08517741551f48 test/results/test0025-aarch64-binary -feaa7dfb1feddc490ff705695558aedefb697cbf51ae487b8ce420d75975181e test/results/test0025-amd64-binary -8dba2e8aec24ce2e6548a118a0f5c5642520c6b1846cdc10a5cb7ae37feed07b test/results/test0025-armv7l-binary -32c446a29dc30a4c409528fba053924ff06a54e509c84aa29ddca5d26b22d03e test/results/test0025-x86-binary -216a373d0eae42de700cbcc9d12f99fd6a9f15cf8e84d17a1098f4e43fb1e050 test/results/test0100-aarch64-binary -e2bcedd9eac8ab95e0ae6c77cef6b3d0d8f4eb1f353f265beed3bc90cbe18af9 test/results/test0100-amd64-binary -8fd43ff39c79d8df7b90efd4478e855bfbf72a6b524bc5253709fb43ce0d1f54 test/results/test0100-armv7l-binary -d26adfafc9568a7426147b9f714f7c082abbd3c52f9f996a7a0c6598a699eaf3 test/results/test0100-knight-posix-binary -9f5740008e758746028e14d2b507c3513f69b7c33c682acb09efd6a388dc43ee test/results/test0100-x86-binary -08e9903be38a9a5c60b6a46e1e36bedd5a6f35181950bd2227451267ce4e2506 test/results/test0101-aarch64-binary -7fe2dc3553dcc61f36b8b85404f59e9adb09b6199d5d573eb6387681ce9a4f94 test/results/test0101-amd64-binary -a7e8a014d95197ecd971a367c6bba536795dd94980c5e204e77de40959fe718c test/results/test0101-armv7l-binary -9826b8da38c7ebd1fbece0bb787fff5e4cc5fe78c13ac235b45c5255ebd8ddb2 test/results/test0101-knight-posix-binary -0fc79efd06f437f53f8a685d363dec91d7bf7ada89bb062f201f7ed08d563e93 test/results/test0101-x86-binary -e56c2fa3f972ffa2dae07f189592cc0390c64cc2bc0e695307da912baaf8642f test/results/test0102-aarch64-binary -a725d8513e61d3fc734368bbe626f229316dbd32b007d39ceb99447b92dceb94 test/results/test0102-amd64-binary -cb1eedb05fb363176d6e5e51dad04eb8db18d3a35b13dc027d14dd142060ab13 test/results/test0102-armv7l-binary -cf530e034524f4334028d8d86945d03b37f6af2223d5e5718fce77ca23db66a3 test/results/test0102-knight-posix-binary -2876a2e173d0b875b7e57579fa59e2f023629868b9c6c680a7e461b1a47f7666 test/results/test0102-x86-binary -f9bdc15f5e5f79d00b91b14c492fa749cfa53b82671a248b382fdadfd3afda66 test/results/test0103-aarch64-binary -70f4d3ebe61cc0d875ff094adf6a48832abdce068060fefc2a53d586db9a9a82 test/results/test0103-amd64-binary -7f79934ccf155de4dde23e1a0b32db8d54902477a3aa5817159aea47c9198ca9 test/results/test0103-armv7l-binary -9b8edc424b015484d0ab54408a78f9547b239da96b59b20b6f0b6a1ad94e685e test/results/test0103-knight-posix-binary -7d8d7e06435f68bdaedb0e84bd1fc83bdcd2f34f134dfbe50e226b1618edfdd1 test/results/test0103-x86-binary -3701c8571e3ca288fb07444b0197ced6e8fecba8b74ad37b35968edcac0cbd91 test/results/test0104-aarch64-binary -90db571f0b5d7cee3ad3e282011969f0dc6ab0d18a1c666e9f61b16910d35f31 test/results/test0104-amd64-binary -c1a50d7d5361ed7b820ed6954e3a19676d0196643f9e3ed9f05bdec37a541eaa test/results/test0104-armv7l-binary -d36a71ab000542bb43e11a0e1e9eb366db87d639f1e49731d1c2032aee35ce4b test/results/test0104-x86-binary -4bd6ef7844e61ed59e0653e41c6a4818868ed05e658189555907f27f8313630a test/results/test0105-aarch64-binary -ff3032e10a6b7813103645b575be73d4a07cd0903e1ac25ec34c04325260d495 test/results/test0105-amd64-binary -8a3ac4ecd762f486feaf0e78305013748ffdc4ee19aba5698e051b4bed8c7853 test/results/test0105-armv7l-binary -52adb6620677330e03a1062fda8893890e16052890df531ec44402bd777e4b55 test/results/test0105-x86-binary -e397c769db7f397e4c8cd994c037c8ef8187362899fb70a52817829c21671254 test/results/test0106-aarch64-binary -f84d26f6023a79e2ae592ec7cc08385ae2693d929941ad0f503cddf31c629ae5 test/results/test0106-amd64-binary -63bd9e5c50de343f05e67caea8f876eed7dee3956be102433c88b0ed87ed59b5 test/results/test0106-armv7l-binary -f3814d352be09f53130b12b49d76c4f968da0caa74bcc9b32a26ce345474ac0f test/results/test0106-knight-native-binary -35c04a4bf519488395ad7c8d240955908a3a2e930375b4690d85c12ee1a79dcd test/results/test0106-knight-posix-binary -7c4b0f43794e314fa8b36c4ae3f61f51c36231157fc06823839ca8788c542eaa test/results/test0106-x86-binary -cc071bd9cf3fe732ac29d2f92e9f08659de8eec843389766d0170c97ab81215e test/results/test1000-aarch64-binary -83157c2e04cf2ef807f12b7b83b8e147458b9675b60401f383b72c582ea59e2d test/results/test1000-amd64-binary -2528c1737d258eb5f6a0f2a50101b8fd78dfabba3393dfd3090d8f20dddb8a63 test/results/test1000-armv7l-binary -ffe73d0f62a299a3d5fba29ff44923f2861b05af94f0dc5fcfa070451bf15850 test/results/test1000-knight-posix-binary -4865b216324bab02b4fe3a1184ed9e30c6ab18b54f9ecd68dcb3de01839500a0 test/results/test1000-x86-binary +79b7437240bc1bb9d36293b7df0d7b5e41118b01920e170056a3574cdb32b9b8 test/results/test0025-aarch64-binary +7d69c08c1b5e7161e4da443a6f765beb232a406453f4878175419f470a923446 test/results/test0025-amd64-binary +26806e703cb424c7b880722828ec24f9c554421b4783f99557044519c6d8a292 test/results/test0025-armv7l-binary +09473ef3da7ec432721ef582bb8f7705f19975a18de6bb6a4531ee0d085a78a3 test/results/test0025-x86-binary +f32c249a1fb11681e87a903cc66427b77a542c1f30e1076bc5e7b89d71355f03 test/results/test0100-aarch64-binary +542bdb658f3f170401baf3a17706d2e661d77e66c9f001199bf16278028cbaa2 test/results/test0100-amd64-binary +2af5d3418feaf3f4dd0cd815fb80a0e33bd431b65457ef088f48d03c91e2c6a2 test/results/test0100-armv7l-binary +57da8d6fc4a83e5fdaa419a6dd13c9d28394dbdafa54d6c29125c5049e62fdb4 test/results/test0100-knight-posix-binary +5c5f320432b31f2f52298e8fb79d0eb930ea67ac8c8affaa71d819adbdd11158 test/results/test0100-x86-binary +ec64c66b91f38215d493a46e241599355c2dcdad6919340f93981d2a24377197 test/results/test0101-aarch64-binary +0af96fedd2a16696b316d3ca4b37709f65cfdbc231f95c8ee76cd6371e810bb6 test/results/test0101-amd64-binary +3007971adbdf7fd1c44bbd34195bd0d85031c9659f93b1538d7fbde737044a0a test/results/test0101-armv7l-binary +d235e598549df24aea45758e74fa4e03a330c78ad3c3403420ee9d8a6478e6df test/results/test0101-knight-posix-binary +9d86a8d2e3bd202d1d590755e8a6d425287bd9d0001d3061a90374f1167d3628 test/results/test0101-x86-binary +c83feda6f529241e6a25949ce0b68e69021c560280571b44e9c52820e60e0c9e test/results/test0102-aarch64-binary +b75f75a3a7aee46d4064a3cca8690cc7ee90d4b3103c964d3654626a992878d5 test/results/test0102-amd64-binary +96d5500026bea8318f3466f75aa08d0dac7d8d7831452accd9498a78a51ff368 test/results/test0102-armv7l-binary +e17290b73faecf575f385c3c24f85911c069ab124bd6f509a0fd37c560fea5b3 test/results/test0102-knight-posix-binary +560180543bafb33b901e2c73a39ae8c7792ec8c1640db031e49ec083adbf4e41 test/results/test0102-x86-binary +40b27b751443fe3308c795ac387a6ec4f5d6e14ab14bd353a0f9628ccd8e0621 test/results/test0103-aarch64-binary +e6fdb92d35353fb5207ae933dc6638bf9d48aaf5e3d7642de5542783b4bd36ef test/results/test0103-amd64-binary +cc2e451fc4a21f99d3919918ccaa35338dc9d915cdbf20c6c420b31d2c71c8ae test/results/test0103-armv7l-binary +bf7461adbff966eb147f68d49b8522414cac412e5805856d7fe6f38b6d2f383d test/results/test0103-knight-posix-binary +d2c3bcd259d06bbd1799036c0a38ce831d36837fae0c86e5036df37a3b9bd114 test/results/test0103-x86-binary +8a56e8101e7924aee1b052d8541666549d12813fd11225a0dcdae998820b5a6f test/results/test0104-aarch64-binary +c00ede1523cf181605614a16e191c72e6eb6da3841dc1beaf30650b3b98feadb test/results/test0104-amd64-binary +e72b85b91cf435dad66cd56d6acdb422d72c387735e4effa59e4c32e8f13ff58 test/results/test0104-armv7l-binary +e00e1764238ba1bd54d793cf46d02a937b5c2fd157e23ee7451ee22193471ae2 test/results/test0104-x86-binary +fb9ca23cb2523a3401907958291e42813eecdc1bb43d4e0b69048531f718a208 test/results/test0105-aarch64-binary +faf1768ecdae46e684dd76bd8adb342c4fe9906646224f01d85f4c1fbfbdd368 test/results/test0105-amd64-binary +e5ab4f572119c1fc661c94b1d903ce5d70b9282ebf49fe05dcc454bf7313d8bc test/results/test0105-armv7l-binary +39c9064b387defa1ab55e3e7088217b073663e95be7727b00f83961eab824ced test/results/test0105-x86-binary +15081d0f4b57e1fa37c7806b021e6d46b4d134f7b8496e4413f460b52a83ab50 test/results/test0106-aarch64-binary +fc31fc8b2d78bd50a4c89eb0e29149626868a70842a3dcb01ea87bb275a9e3c2 test/results/test0106-amd64-binary +0dfd9118b0ccab36fba948fa1952b4ab7bab28cdd57cf10c7da66240f5dcc598 test/results/test0106-armv7l-binary +965bdf7049179199b9f423250a186c7b64ea55326c3249127d2daf7d42ae53cc test/results/test0106-knight-native-binary +0a929d6990caee3e93b1188a38fd3041c6f8e46d25a386024647c0f05c33bce7 test/results/test0106-knight-posix-binary +331ffb5284bd824494ad61a3b0b2dff5681a63ab604e9a06100af531ae237148 test/results/test0106-x86-binary +7c37ee46b67c400f6ab8740417f59f65fb45ead82e5f9c8872efb92c7a663077 test/results/test1000-aarch64-binary +e70c2d890645766c9c4e648c3e92bfdeaf477c957458ef5d0957c424f6bdc4c0 test/results/test1000-amd64-binary +53ceced359aa2e226c9100dd2cf078b1ba2e72406f76e1bb688dcf14a17b6a12 test/results/test1000-armv7l-binary +99b6e2cb87498493364ecbd6ac9e27e79f510b90fe9560eb07f60011343fcbd2 test/results/test1000-knight-posix-binary +40e0a3e1db4dd6c88f50489280cccf18fa39684e06d6a1683f93c2f99d96715a test/results/test1000-x86-binary diff --git a/test/test0019/hello-knight-posix.sh b/test/test0019/hello-knight-posix.sh index 7ed1cc5..6a84494 100755 --- a/test/test0019/hello-knight-posix.sh +++ b/test/test0019/hello-knight-posix.sh @@ -31,7 +31,6 @@ bin/M2-Planet \ -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ - -f functions/file_print.c \ -f test/test0019/getopt.c \ -o ${TMPDIR}/getopt.M1 \ || exit 1 diff --git a/test/test0019/run_test.sh b/test/test0019/run_test.sh index de6dabe..227e214 100755 --- a/test/test0019/run_test.sh +++ b/test/test0019/run_test.sh @@ -34,7 +34,6 @@ bin/M2-Planet \ -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ - -f functions/file_print.c \ -f test/test0019/getopt.c \ -o ${TMPDIR}/getopt.M1 \ || exit 1 diff --git a/test/test0021/chdir.c b/test/test0021/chdir.c index b8d9a16..02a01da 100644 --- a/test/test0021/chdir.c +++ b/test/test0021/chdir.c @@ -25,7 +25,6 @@ int match(char* a, char* b); char* get_current_dir_name(); -void file_print(char* s, FILE* f); char* copy_string(char* target, char* source) { @@ -43,7 +42,7 @@ char* prepend_string(char* add, char* base) char* ret = calloc(MAX_STRING, sizeof(char)); if(NULL == ret) { - file_print("calloc failed in prepend_string\n", stderr); + fputs("calloc failed in prepend_string\n", stderr); exit(EXIT_FAILURE); } copy_string(copy_string(ret, add), base); diff --git a/test/test0021/hello-knight-posix.sh b/test/test0021/hello-knight-posix.sh index e5f7b25..8432404 100755 --- a/test/test0021/hello-knight-posix.sh +++ b/test/test0021/hello-knight-posix.sh @@ -29,7 +29,6 @@ bin/M2-Planet \ -f M2libc/knight/Linux/fcntl.h \ -f M2libc/stdio.c \ -f functions/match.c \ - -f functions/file_print.c \ -f test/test0021/chdir.c \ -o ${TMPDIR}/chdir.M1 \ || exit 1 diff --git a/test/test0021/run_test.sh b/test/test0021/run_test.sh index 6b87260..1c080de 100755 --- a/test/test0021/run_test.sh +++ b/test/test0021/run_test.sh @@ -32,7 +32,6 @@ bin/M2-Planet \ -f M2libc/${ARCH}/Linux/fcntl.h \ -f M2libc/stdio.c \ -f functions/match.c \ - -f functions/file_print.c \ -f test/test0021/chdir.c \ --debug \ -o ${TMPDIR}/chdir.M1 \ diff --git a/test/test0022/continue.c b/test/test0022/continue.c index 49601cd..a83c2f5 100644 --- a/test/test0022/continue.c +++ b/test/test0022/continue.c @@ -19,7 +19,6 @@ #include char* numerate_number(int a); -void file_print(char* s, FILE* f); int main() { @@ -27,7 +26,7 @@ int main() int j; for(i = 0; i < 10; i = i + 1) { - file_print(numerate_number(i), stdout); + fputs(numerate_number(i), stdout); if(i != 1) continue; fputc(' ', stdout); } @@ -39,8 +38,8 @@ int main() for(j = 0; j < 10; j = j + 1) { if(j == 2) continue; - file_print(numerate_number(i), stdout); - file_print(numerate_number(j), stdout); + fputs(numerate_number(i), stdout); + fputs(numerate_number(j), stdout); fputc(' ', stdout); } } @@ -51,7 +50,7 @@ int main() while(i < 9) { i = i + 1; - file_print(numerate_number(i), stdout); + fputs(numerate_number(i), stdout); if(i != 3) continue; fputc(' ', stdout); } @@ -67,8 +66,8 @@ int main() { j = j + 1; if(j == 4) continue; - file_print(numerate_number(i), stdout); - file_print(numerate_number(j), stdout); + fputs(numerate_number(i), stdout); + fputs(numerate_number(j), stdout); fputc(' ', stdout); } } @@ -79,7 +78,7 @@ int main() do { i = i + 1; - file_print(numerate_number(i), stdout); + fputs(numerate_number(i), stdout); if(i != 5) continue; fputc(' ', stdout); }while(i < 9); @@ -95,8 +94,8 @@ int main() { j = j + 1; if(j == 6) continue; - file_print(numerate_number(i), stdout); - file_print(numerate_number(j), stdout); + fputs(numerate_number(i), stdout); + fputs(numerate_number(j), stdout); fputc(' ', stdout); }while(j < 9); }while(i < 9); diff --git a/test/test0022/hello-knight-posix.sh b/test/test0022/hello-knight-posix.sh index 0102506..f41939d 100755 --- a/test/test0022/hello-knight-posix.sh +++ b/test/test0022/hello-knight-posix.sh @@ -30,7 +30,6 @@ bin/M2-Planet \ -f M2libc/stdio.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ - -f functions/file_print.c \ -f test/test0022/continue.c \ -o ${TMPDIR}/continue.M1 \ || exit 1 diff --git a/test/test0022/run_test.sh b/test/test0022/run_test.sh index 728a1d8..b020fb1 100755 --- a/test/test0022/run_test.sh +++ b/test/test0022/run_test.sh @@ -33,7 +33,6 @@ bin/M2-Planet \ -f M2libc/stdio.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ - -f functions/file_print.c \ -f test/test0022/continue.c \ --debug \ -o ${TMPDIR}/continue.M1 \ diff --git a/test/test0100/blood-elf.c b/test/test0100/blood-elf.c index daefb67..41cebd1 100644 --- a/test/test0100/blood-elf.c +++ b/test/test0100/blood-elf.c @@ -32,7 +32,6 @@ #define FALSE 0 //CONSTANT FALSE 0 -void file_print(char* s, FILE* f); int match(char* a, char* b); struct entry @@ -102,9 +101,9 @@ void first_pass(struct entry* input) if(NULL == source_file) { - file_print("The file: ", stderr); - file_print(input->name, stderr); - file_print(" can not be opened!\n", stderr); + fputs("The file: ", stderr); + fputs(input->name, stderr); + fputs(" can not be opened!\n", stderr); exit(EXIT_FAILURE); } @@ -136,19 +135,19 @@ void output_debug(struct entry* node, int stage) { if(stage) { - file_print(":ELF_str_", output); - file_print(i->name, output); - file_print("\n\x22", output); - file_print(i->name, output); - file_print("\x22\n", output); + fputs(":ELF_str_", output); + fputs(i->name, output); + fputs("\n\x22", output); + fputs(i->name, output); + fputs("\x22\n", output); } else { - file_print("%ELF_str_", output); - file_print(i->name, output); - file_print(">ELF_str\n&", output); - file_print(i->name, output); - file_print("\n%10000\n!2\n!0\n@1\n", output); + fputs("%ELF_str_", output); + fputs(i->name, output); + fputs(">ELF_str\n&", output); + fputs(i->name, output); + fputs("\n%10000\n!2\n!0\n@1\n", output); } } } @@ -185,9 +184,9 @@ int main(int argc, char **argv) } else if(match(argv[option_index], "-h") || match(argv[option_index], "--help")) { - file_print("Usage: ", stderr); - file_print(argv[0], stderr); - file_print(" -f FILENAME1 {-f FILENAME2}\n", stderr); + fputs("Usage: ", stderr); + fputs(argv[0], stderr); + fputs(" -f FILENAME1 {-f FILENAME2}\n", stderr); exit(EXIT_SUCCESS); } else if(match(argv[option_index], "-f") || match(argv[option_index], "--file")) @@ -205,21 +204,21 @@ int main(int argc, char **argv) if(NULL == output) { - file_print("The file: ", stderr); - file_print(input->name, stderr); - file_print(" can not be opened!\n", stderr); + fputs("The file: ", stderr); + fputs(input->name, stderr); + fputs(" can not be opened!\n", stderr); exit(EXIT_FAILURE); } option_index = option_index + 2; } else if(match(argv[option_index], "-V") || match(argv[option_index], "--version")) { - file_print("blood-elf 0.1\n(Basically Launches Odd Object Dump ExecutabLe Files\n", stdout); + fputs("blood-elf 0.1\n(Basically Launches Odd Object Dump ExecutabLe Files\n", stdout); exit(EXIT_SUCCESS); } else { - file_print("Unknown option\n", stderr); + fputs("Unknown option\n", stderr); exit(EXIT_FAILURE); } } @@ -236,11 +235,11 @@ int main(int argc, char **argv) /* Reverse their order */ jump_table = reverse_list(jump_table); - file_print(":ELF_str\n!0\n", output); + fputs(":ELF_str\n!0\n", output); output_debug(jump_table, TRUE); - file_print("%0\n:ELF_sym\n%0\n%0\n%0\n!0\n!0\n@1\n", output); + fputs("%0\n:ELF_sym\n%0\n%0\n%0\n!0\n!0\n@1\n", output); output_debug(jump_table, FALSE); - file_print("\n:ELF_end\n", output); + fputs("\n:ELF_end\n", output); if (output != stdout) { fclose(output); diff --git a/test/test0100/hello-knight-posix.sh b/test/test0100/hello-knight-posix.sh index 917fc04..46fa5d1 100755 --- a/test/test0100/hello-knight-posix.sh +++ b/test/test0100/hello-knight-posix.sh @@ -28,7 +28,6 @@ mkdir -p ${TMPDIR} -f M2libc/stdlib.c \ -f M2libc/knight/Linux/fcntl.h \ -f M2libc/stdio.c \ - -f functions/file_print.c \ -f functions/match.c \ -f test/test0100/blood-elf.c \ -o ${TMPDIR}/blood-elf.M1 \ diff --git a/test/test0100/run_test.sh b/test/test0100/run_test.sh index c3fd31f..fd2004b 100755 --- a/test/test0100/run_test.sh +++ b/test/test0100/run_test.sh @@ -31,7 +31,6 @@ mkdir -p ${TMPDIR} -f M2libc/stdlib.c \ -f M2libc/${ARCH}/Linux/fcntl.h \ -f M2libc/stdio.c \ - -f functions/file_print.c \ -f functions/match.c \ -f test/test0100/blood-elf.c \ --debug \ diff --git a/test/test0101/hello-knight-posix.sh b/test/test0101/hello-knight-posix.sh index 1443822..62f3671 100755 --- a/test/test0101/hello-knight-posix.sh +++ b/test/test0101/hello-knight-posix.sh @@ -28,7 +28,6 @@ mkdir -p ${TMPDIR} -f M2libc/stdlib.c \ -f M2libc/knight/Linux/fcntl.h \ -f M2libc/stdio.c \ - -f functions/file_print.c \ -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ diff --git a/test/test0101/hex2_linker.c b/test/test0101/hex2_linker.c index 44bcec7..d5d725e 100644 --- a/test/test0101/hex2_linker.c +++ b/test/test0101/hex2_linker.c @@ -30,7 +30,6 @@ #define FALSE 0 //CONSTANT FALSE 0 -void file_print(char* s, FILE* f); int match(char* a, char* b); char* numerate_number(int a); int numerate_string(char *a); @@ -64,10 +63,10 @@ int ALIGNED; void line_error() { - file_print(filename, stderr); - file_print(":", stderr); - file_print(numerate_number(linenumber), stderr); - file_print(" :", stderr); + fputs(filename, stderr); + fputs(":", stderr); + fputs(numerate_number(linenumber), stderr); + fputs(" :", stderr); } int consume_token(FILE* source_file) @@ -131,9 +130,9 @@ unsigned GetTarget(char* c) return i->target; } } - file_print("Target label ", stderr); - file_print(c, stderr); - file_print(" is not valid\n", stderr); + fputs("Target label ", stderr); + fputs(c, stderr); + fputs(" is not valid\n", stderr); exit(EXIT_FAILURE); } @@ -164,9 +163,9 @@ void range_check(int displacement, int number_of_bytes) { if((8388607 < displacement) || (displacement < -8388608)) { - file_print("A displacement of ", stderr); - file_print(numerate_number(displacement), stderr); - file_print(" does not fit in 3 bytes\n", stderr); + fputs("A displacement of ", stderr); + fputs(numerate_number(displacement), stderr); + fputs(" does not fit in 3 bytes\n", stderr); exit(EXIT_FAILURE); } return; @@ -175,9 +174,9 @@ void range_check(int displacement, int number_of_bytes) { if((32767 < displacement) || (displacement < -32768)) { - file_print("A displacement of ", stderr); - file_print(numerate_number(displacement), stderr); - file_print(" does not fit in 2 bytes\n", stderr); + fputs("A displacement of ", stderr); + fputs(numerate_number(displacement), stderr); + fputs(" does not fit in 2 bytes\n", stderr); exit(EXIT_FAILURE); } return; @@ -186,15 +185,15 @@ void range_check(int displacement, int number_of_bytes) { if((127 < displacement) || (displacement < -128)) { - file_print("A displacement of ", stderr); - file_print(numerate_number(displacement), stderr); - file_print(" does not fit in 1 byte\n", stderr); + fputs("A displacement of ", stderr); + fputs(numerate_number(displacement), stderr); + fputs(" does not fit in 1 byte\n", stderr); exit(EXIT_FAILURE); } return; } - file_print("Invalid number of bytes given\n", stderr); + fputs("Invalid number of bytes given\n", stderr); exit(EXIT_FAILURE); } @@ -237,9 +236,9 @@ int Architectural_displacement(int target, int base) if (target & 3) { line_error(); - file_print("error: Unaligned branch target: ", stderr); - file_print(scratch, stderr); - file_print(", aborting\n", stderr); + fputs("error: Unaligned branch target: ", stderr); + fputs(scratch, stderr); + fputs(", aborting\n", stderr); exit(EXIT_FAILURE); } /* @@ -263,7 +262,7 @@ int Architectural_displacement(int target, int base) return ((target - base) - 8 + (3 & base)); } - file_print("Unknown Architecture, aborting before harm is done\n", stderr); + fputs("Unknown Architecture, aborting before harm is done\n", stderr); exit(EXIT_FAILURE); } @@ -277,7 +276,7 @@ void Update_Pointer(char ch) else { line_error(); - file_print("storePointer given unknown\n", stderr); + fputs("storePointer given unknown\n", stderr); exit(EXIT_FAILURE); } } @@ -320,9 +319,9 @@ void storePointer(char ch, FILE* source_file) else { line_error(); - file_print("error: storePointer reached impossible case: ch=", stderr); + fputs("error: storePointer reached impossible case: ch=", stderr); fputc(ch, stderr); - file_print("\n", stderr); + fputs("\n", stderr); exit(EXIT_FAILURE); } } @@ -459,9 +458,9 @@ void first_pass(struct input_files* input) if(NULL == source_file) { - file_print("The file: ", stderr); - file_print(input->filename, stderr); - file_print(" can not be opened!\n", stderr); + fputs("The file: ", stderr); + fputs(input->filename, stderr); + fputs(" can not be opened!\n", stderr); exit(EXIT_FAILURE); } @@ -510,9 +509,9 @@ void second_pass(struct input_files* input) /* Something that should never happen */ if(NULL == source_file) { - file_print("The file: ", stderr); - file_print(input->filename, stderr); - file_print(" can not be opened!\nWTF-pass2\n", stderr); + fputs("The file: ", stderr); + fputs(input->filename, stderr); + fputs(" can not be opened!\nWTF-pass2\n", stderr); exit(EXIT_FAILURE); } @@ -580,9 +579,9 @@ int main(int argc, char **argv) else if(match("armv7l", arch)) Architecture = 40; else { - file_print("Unknown architecture: ", stderr); - file_print(arch, stderr); - file_print(" know values are: knight-native, knight-posix, x86, amd64 and armv7l", stderr); + fputs("Unknown architecture: ", stderr); + fputs(arch, stderr); + fputs(" know values are: knight-native, knight-posix, x86, amd64 and armv7l", stderr); } option_index = option_index + 2; } @@ -598,12 +597,12 @@ int main(int argc, char **argv) } else if(match(argv[option_index], "-h") || match(argv[option_index], "--help")) { - file_print("Usage: ", stderr); - file_print(argv[0], stderr); - file_print(" -f FILENAME1 {-f FILENAME2} (--BigEndian|--LittleEndian)", stderr); - file_print(" [--BaseAddress 12345] [--architecture name]\nArchitecture", stderr); - file_print(" knight-native, knight-posix, x86, amd64 and armv7\n", stderr); - file_print("To leverage octal or binary input: --octal, --binary\n", stderr); + fputs("Usage: ", stderr); + fputs(argv[0], stderr); + fputs(" -f FILENAME1 {-f FILENAME2} (--BigEndian|--LittleEndian)", stderr); + fputs(" [--BaseAddress 12345] [--architecture name]\nArchitecture", stderr); + fputs(" knight-native, knight-posix, x86, amd64 and armv7\n", stderr); + fputs("To leverage octal or binary input: --octal, --binary\n", stderr); exit(EXIT_SUCCESS); } else if(match(argv[option_index], "-f") || match(argv[option_index], "--file")) @@ -621,9 +620,9 @@ int main(int argc, char **argv) if(NULL == output) { - file_print("The file: ", stderr); - file_print(argv[option_index + 1], stderr); - file_print(" can not be opened!\n", stderr); + fputs("The file: ", stderr); + fputs(argv[option_index + 1], stderr); + fputs(" can not be opened!\n", stderr); exit(EXIT_FAILURE); } option_index = option_index + 2; @@ -635,12 +634,12 @@ int main(int argc, char **argv) } else if(match(argv[option_index], "-V") || match(argv[option_index], "--version")) { - file_print("hex2 0.3\n", stdout); + fputs("hex2 0.3\n", stdout); exit(EXIT_SUCCESS); } else { - file_print("Unknown option\n", stderr); + fputs("Unknown option\n", stderr); exit(EXIT_FAILURE); } } @@ -670,7 +669,7 @@ int main(int argc, char **argv) /* 488 = 750 in octal */ if(0 != chmod(output_file, 488)) { - file_print("Unable to change permissions\n", stderr); + fputs("Unable to change permissions\n", stderr); exit(EXIT_FAILURE); } } diff --git a/test/test0101/run_test.sh b/test/test0101/run_test.sh index c94ed4a..87caebb 100755 --- a/test/test0101/run_test.sh +++ b/test/test0101/run_test.sh @@ -31,7 +31,6 @@ mkdir -p ${TMPDIR} -f M2libc/stdlib.c \ -f M2libc/${ARCH}/Linux/fcntl.h \ -f M2libc/stdio.c \ - -f functions/file_print.c \ -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ diff --git a/test/test0102/M1-macro.c b/test/test0102/M1-macro.c index 00a9f83..889b77b 100644 --- a/test/test0102/M1-macro.c +++ b/test/test0102/M1-macro.c @@ -62,7 +62,6 @@ int in_set(int c, char* s); int match(char* a, char* b); int numerate_string(char *a); int string_length(char* a); -void file_print(char* s, FILE* f); void require(int bool, char* error); struct blob @@ -100,10 +99,10 @@ struct blob** hash_table; void line_error(char* filename, int linenumber) { - file_print(filename, stderr); - file_print(":", stderr); - file_print(numerate_number(linenumber), stderr); - file_print(" :", stderr); + fputs(filename, stderr); + fputs(":", stderr); + fputs(numerate_number(linenumber), stderr); + fputs(" :", stderr); } void ClearScratch() @@ -266,9 +265,9 @@ struct blob* store_string(char c, char* filename) if(max_string == i) { line_error(filename, linenumber); - file_print("String: ", stderr); - file_print(SCRATCH, stderr); - file_print(" exceeds max string size\n", stderr); + fputs("String: ", stderr); + fputs(SCRATCH, stderr); + fputs(" exceeds max string size\n", stderr); exit(EXIT_FAILURE); } } while(ch != c); @@ -348,9 +347,9 @@ void line_macro(struct Token* p) if(PROCESSED == i->next->contents->type) { line_error(i->filename, i->linenumber); - file_print("Multiple definitions for macro ", stderr); - file_print(i->next->contents->Text, stderr); - file_print("\n", stderr); + fputs("Multiple definitions for macro ", stderr); + fputs(i->next->contents->Text, stderr); + fputs("\n", stderr); exit(EXIT_FAILURE); } @@ -504,11 +503,11 @@ void bound_values(int displacement, int number_of_bytes, int low, int high) { if((high < displacement) || (displacement < low)) { - file_print("A displacement of ", stderr); - file_print(numerate_number(displacement), stderr); - file_print(" does not fit in ", stderr); - file_print(numerate_number(number_of_bytes), stderr); - file_print(" bytes\n", stderr); + fputs("A displacement of ", stderr); + fputs(numerate_number(displacement), stderr); + fputs(" does not fit in ", stderr); + fputs(numerate_number(number_of_bytes), stderr); + fputs(" bytes\n", stderr); exit(EXIT_FAILURE); } } @@ -532,7 +531,7 @@ void range_check(int displacement, int number_of_bytes) return; } - file_print("Received an invalid number of bytes in range_check\n", stderr); + fputs("Received an invalid number of bytes in range_check\n", stderr); exit(EXIT_FAILURE); } @@ -628,10 +627,10 @@ char* express_number(int value, char c) } else { - file_print("Given symbol ", stderr); + fputs("Given symbol ", stderr); fputc(c, stderr); - file_print(" to express immediate value ", stderr); - file_print(numerate_number(value), stderr); + fputs(" to express immediate value ", stderr); + fputs(numerate_number(value), stderr); fputc('\n', stderr); exit(EXIT_FAILURE); } @@ -655,7 +654,7 @@ char* express_number(int value, char c) } else { - file_print("Got invalid ByteMode in express_number\n", stderr); + fputs("Got invalid ByteMode in express_number\n", stderr); exit(EXIT_FAILURE); } @@ -699,7 +698,7 @@ void eval_immediates(struct blob* p) } else { - file_print("Unknown architecture received in eval_immediates\n", stderr); + fputs("Unknown architecture received in eval_immediates\n", stderr); exit(EXIT_FAILURE); } } @@ -718,15 +717,15 @@ void print_hex(struct Token* p) } else if(NULL != i->contents->Expression) { - file_print(i->contents->Expression, destination_file); + fputs(i->contents->Expression, destination_file); if(NEWLINE != i->next->contents->type) fputc(' ', destination_file); } else { line_error(i->filename, i->linenumber); - file_print("Received invalid other; ", stderr); - file_print(i->contents->Text, stderr); - file_print("\n", stderr); + fputs("Received invalid other; ", stderr); + fputs(i->contents->Text, stderr); + fputs("\n", stderr); exit(EXIT_FAILURE); } } @@ -789,9 +788,9 @@ int main(int argc, char **argv) else if(match("aarch64", arch)) Architecture = AARM64; else { - file_print("Unknown architecture: ", stderr); - file_print(arch, stderr); - file_print(" know values are: knight-native, knight-posix, x86, amd64, armv7l and aarch64", stderr); + fputs("Unknown architecture: ", stderr); + fputs(arch, stderr); + fputs(" know values are: knight-native, knight-posix, x86, amd64, armv7l and aarch64", stderr); exit(EXIT_FAILURE); } option_index = option_index + 2; @@ -803,11 +802,11 @@ int main(int argc, char **argv) } else if(match(argv[option_index], "-h") || match(argv[option_index], "--help")) { - file_print("Usage: ", stderr); - file_print(argv[0], stderr); - file_print(" --file FILENAME1 {-f FILENAME2} (--big-endian|--little-endian) ", stderr); - file_print("[--architecture name]\nArchitectures: knight-native, knight-posix, x86, amd64 and armv7\n", stderr); - file_print("To leverage octal or binary output: --octal, --binary\n", stderr); + fputs("Usage: ", stderr); + fputs(argv[0], stderr); + fputs(" --file FILENAME1 {-f FILENAME2} (--big-endian|--little-endian) ", stderr); + fputs("[--architecture name]\nArchitectures: knight-native, knight-posix, x86, amd64 and armv7\n", stderr); + fputs("To leverage octal or binary output: --octal, --binary\n", stderr); exit(EXIT_SUCCESS); } else if(match(argv[option_index], "-f") || match(argv[option_index], "--file")) @@ -817,9 +816,9 @@ int main(int argc, char **argv) if(NULL == source_file) { - file_print("The file: ", stderr); - file_print(argv[option_index + 1], stderr); - file_print(" can not be opened!\n", stderr); + fputs("The file: ", stderr); + fputs(argv[option_index + 1], stderr); + fputs(" can not be opened!\n", stderr); exit(EXIT_FAILURE); } @@ -835,9 +834,9 @@ int main(int argc, char **argv) if(NULL == destination_file) { - file_print("The file: ", stderr); - file_print(argv[option_index + 1], stderr); - file_print(" can not be opened!\n", stderr); + fputs("The file: ", stderr); + fputs(argv[option_index + 1], stderr); + fputs(" can not be opened!\n", stderr); exit(EXIT_FAILURE); } option_index = option_index + 2; @@ -849,19 +848,19 @@ int main(int argc, char **argv) } else if(match(argv[option_index], "-V") || match(argv[option_index], "--version")) { - file_print("M1 1.0.0\n", stdout); + fputs("M1 1.0.0\n", stdout); exit(EXIT_SUCCESS); } else { - file_print("Unknown option\n", stderr); + fputs("Unknown option\n", stderr); exit(EXIT_FAILURE); } } if(NULL == token_list) { - file_print("Either no input files were given or they were empty\n", stderr); + fputs("Either no input files were given or they were empty\n", stderr); exit(EXIT_FAILURE); } diff --git a/test/test0102/hello-knight-posix.sh b/test/test0102/hello-knight-posix.sh index cd84ef5..534cc43 100755 --- a/test/test0102/hello-knight-posix.sh +++ b/test/test0102/hello-knight-posix.sh @@ -28,7 +28,6 @@ mkdir -p ${TMPDIR} -f M2libc/stdlib.c \ -f M2libc/knight/Linux/fcntl.h \ -f M2libc/stdio.c \ - -f functions/file_print.c \ -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ diff --git a/test/test0102/run_test.sh b/test/test0102/run_test.sh index 8d43cb1..6a41115 100755 --- a/test/test0102/run_test.sh +++ b/test/test0102/run_test.sh @@ -31,7 +31,6 @@ mkdir -p ${TMPDIR} -f M2libc/stdlib.c \ -f M2libc/${ARCH}/Linux/fcntl.h \ -f M2libc/stdio.c \ - -f functions/file_print.c \ -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ diff --git a/test/test0103/get_machine.c b/test/test0103/get_machine.c index 1e7c882..2c17a95 100644 --- a/test/test0103/get_machine.c +++ b/test/test0103/get_machine.c @@ -20,7 +20,6 @@ #include #include #include -void file_print(char* s, FILE* f); int match(char* a, char* b); #define TRUE 1 @@ -54,30 +53,30 @@ int main(int argc, char **argv) } else if(match(argv[option_index], "-V") || match(argv[option_index], "--version")) { - file_print("get_machine 0.1\n", stdout); + fputs("get_machine 0.1\n", stdout); exit(EXIT_SUCCESS); } else { - file_print("Unknown option\n", stderr); + fputs("Unknown option\n", stderr); exit(EXIT_FAILURE); } } struct utsname* unameData = calloc(1, sizeof(struct utsname)); uname(unameData); - if(override) file_print(override_string, stdout); + if(override) fputs(override_string, stdout); else if(!exact) { if(match("i386", unameData->machine) || match("i486", unameData->machine) || match("i586", unameData->machine) || match("i686", unameData->machine) || - match("i686-pae", unameData->machine)) file_print("x86", stdout); - else if(match("x86_64", unameData->machine)) file_print("amd64", stdout); - else file_print(unameData->machine, stdout); + match("i686-pae", unameData->machine)) fputs("x86", stdout); + else if(match("x86_64", unameData->machine)) fputs("amd64", stdout); + else fputs(unameData->machine, stdout); } - else file_print(unameData->machine, stdout); - file_print("\n", stdout); + else fputs(unameData->machine, stdout); + fputs("\n", stdout); return EXIT_SUCCESS; } diff --git a/test/test0103/hello-knight-posix.sh b/test/test0103/hello-knight-posix.sh index ebb8fc4..1762bee 100755 --- a/test/test0103/hello-knight-posix.sh +++ b/test/test0103/hello-knight-posix.sh @@ -28,7 +28,6 @@ mkdir -p ${TMPDIR} -f M2libc/stdlib.c \ -f M2libc/knight/Linux/fcntl.h \ -f M2libc/stdio.c \ - -f functions/file_print.c \ -f functions/match.c \ -f test/test0103/get_machine.c \ -o ${TMPDIR}/get_machine.M1 \ diff --git a/test/test0103/run_test.sh b/test/test0103/run_test.sh index cc39376..23ff5cc 100755 --- a/test/test0103/run_test.sh +++ b/test/test0103/run_test.sh @@ -31,7 +31,6 @@ mkdir -p ${TMPDIR} -f M2libc/stdlib.c \ -f M2libc/${ARCH}/Linux/fcntl.h \ -f M2libc/stdio.c \ - -f functions/file_print.c \ -f functions/match.c \ -f test/test0103/get_machine.c \ --debug \ diff --git a/test/test0104/kaem.c b/test/test0104/kaem.c index 33e5572..3e34aa7 100644 --- a/test/test0104/kaem.c +++ b/test/test0104/kaem.c @@ -31,7 +31,6 @@ char* numerate_number(int a); int match(char* a, char* b); -void file_print(char* s, FILE* f); char** tokens; int command_done; @@ -49,7 +48,7 @@ void collect_comment(FILE* input) c = fgetc(input); if(-1 == c) { - file_print("IMPROPERLY TERMINATED LINE COMMENT!\nABORTING HARD\n", stderr); + fputs("IMPROPERLY TERMINATED LINE COMMENT!\nABORTING HARD\n", stderr); exit(EXIT_FAILURE); } } while('\n' != c); @@ -64,7 +63,7 @@ int collect_string(FILE* input, int index, char* target) c = fgetc(input); if(-1 == c) { /* We never should hit EOF while collecting a RAW string */ - file_print("IMPROPERLY TERMINATED RAW string!\nABORTING HARD\n", stderr); + fputs("IMPROPERLY TERMINATED RAW string!\nABORTING HARD\n", stderr); exit(EXIT_FAILURE); } else if('"' == c) @@ -88,7 +87,7 @@ char* collect_token(FILE* input) c = fgetc(input); if(-1 == c) { /* Deal with end of file */ - file_print("execution complete\n", stderr); + fputs("execution complete\n", stderr); exit(EXIT_SUCCESS); } else if((' ' == c) || ('\t' == c)) @@ -314,13 +313,13 @@ void execute_commands(FILE* script, char** envp, int envp_length) if(VERBOSE && (0 < i)) { - file_print(" +> ", stdout); + fputs(" +> ", stdout); for(j = 0; j < i; j = j + 1) { - file_print(tokens[j], stdout); + fputs(tokens[j], stdout); fputc(' ', stdout); } - file_print("\n", stdout); + fputs("\n", stdout); } if(0 < i) @@ -338,16 +337,16 @@ void execute_commands(FILE* script, char** envp, int envp_length) program = find_executable(tokens[0], PATH); if(NULL == program) { - file_print(tokens[0], stderr); - file_print("Some weird shit went down with: ", stderr); - file_print("\n", stderr); + fputs(tokens[0], stderr); + fputs("Some weird shit went down with: ", stderr); + fputs("\n", stderr); exit(EXIT_FAILURE); } f = fork(); if (f == -1) { - file_print("fork() failure", stderr); + fputs("fork() failure", stderr); exit(EXIT_FAILURE); } else if (f == 0) @@ -364,9 +363,9 @@ void execute_commands(FILE* script, char** envp, int envp_length) if(STRICT && (0 != status)) { /* Clearly the script hit an issue that should never have happened */ - file_print("Subprocess error ", stderr); - file_print(numerate_number(status), stderr); - file_print("\nABORTING HARD\n", stderr); + fputs("Subprocess error ", stderr); + fputs(numerate_number(status), stderr); + fputs("\nABORTING HARD\n", stderr); /* stop to prevent damage */ exit(EXIT_FAILURE); } @@ -411,7 +410,7 @@ int main(int argc, char** argv, char** envp) } else if(match(argv[i], "-h") || match(argv[i], "--help")) { - file_print("kaem only accepts --help, --version, --file, --verbose, --nightmare-mode or no arguments\n", stdout); + fputs("kaem only accepts --help, --version, --file, --verbose, --nightmare-mode or no arguments\n", stdout); exit(EXIT_SUCCESS); } else if(match(argv[i], "-f") || match(argv[i], "--file")) @@ -421,13 +420,13 @@ int main(int argc, char** argv, char** envp) } else if(match(argv[i], "n") || match(argv[i], "--nightmare-mode")) { - file_print("Begin nightmare", stdout); + fputs("Begin nightmare", stdout); envp = NULL; i = i + 1; } else if(match(argv[i], "-V") || match(argv[i], "--version")) { - file_print("kaem version 0.6.0\n", stdout); + fputs("kaem version 0.6.0\n", stdout); exit(EXIT_SUCCESS); } else if(match(argv[i], "--verbose")) @@ -442,7 +441,7 @@ int main(int argc, char** argv, char** envp) } else { - file_print("UNKNOWN ARGUMENT\n", stdout); + fputs("UNKNOWN ARGUMENT\n", stdout); exit(EXIT_FAILURE); } } @@ -451,9 +450,9 @@ int main(int argc, char** argv, char** envp) if(NULL == script) { - file_print("The file: ", stderr); - file_print(filename, stderr); - file_print(" can not be opened!\n", stderr); + fputs("The file: ", stderr); + fputs(filename, stderr); + fputs(" can not be opened!\n", stderr); exit(EXIT_FAILURE); } diff --git a/test/test0104/run_test.sh b/test/test0104/run_test.sh index 19cc25e..1837294 100755 --- a/test/test0104/run_test.sh +++ b/test/test0104/run_test.sh @@ -31,7 +31,6 @@ mkdir -p ${TMPDIR} -f M2libc/stdlib.c \ -f M2libc/${ARCH}/Linux/fcntl.h \ -f M2libc/stdio.c \ - -f functions/file_print.c \ -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ diff --git a/test/test0105/lisp.c b/test/test0105/lisp.c index 3d42445..b003fd9 100644 --- a/test/test0105/lisp.c +++ b/test/test0105/lisp.c @@ -85,9 +85,9 @@ int main(int argc, char **argv) console_output = fopen(argv[i + 1], "w"); if(NULL == console_output) { - file_print("The file: ", stderr); - file_print(argv[i + 1], stderr); - file_print(" does not appear writable\n", stderr); + fputs("The file: ", stderr); + fputs(argv[i + 1], stderr); + fputs(" does not appear writable\n", stderr); exit(EXIT_FAILURE); } i = i + 2; @@ -98,9 +98,9 @@ int main(int argc, char **argv) new->file = fopen(argv[i + 1], "r"); if(NULL == new->file) { - file_print("The file: ", stderr); - file_print(argv[i + 1], stderr); - file_print(" does not appear readable\n", stderr); + fputs("The file: ", stderr); + fputs(argv[i + 1], stderr); + fputs(" does not appear readable\n", stderr); exit(EXIT_FAILURE); } new->next = essential; @@ -109,9 +109,9 @@ int main(int argc, char **argv) } else if(match(argv[i], "-h") || match(argv[i], "--help")) { - file_print("Usage: ", stdout); - file_print(argv[0], stdout); - file_print(" -f FILENAME1 {-f FILENAME2}\n", stdout); + fputs("Usage: ", stdout); + fputs(argv[0], stdout); + fputs(" -f FILENAME1 {-f FILENAME2}\n", stdout); exit(EXIT_SUCCESS); } else if(match(argv[i], "-m") || match(argv[i], "--memory")) @@ -124,21 +124,21 @@ int main(int argc, char **argv) file_output = fopen(argv[i + 1], "w"); if(NULL == file_output) { - file_print("The file: ", stderr); - file_print(argv[i + 1], stderr); - file_print(" does not appear writable\n", stderr); + fputs("The file: ", stderr); + fputs(argv[i + 1], stderr); + fputs(" does not appear writable\n", stderr); exit(EXIT_FAILURE); } i = i + 2; } else if(match(argv[i], "-v") || match(argv[i], "--version")) { - file_print("Slow_Lisp 0.1\n", stdout); + fputs("Slow_Lisp 0.1\n", stdout); exit(EXIT_SUCCESS); } else { - file_print("Unknown option\n", stderr); + fputs("Unknown option\n", stderr); exit(EXIT_FAILURE); } } diff --git a/test/test0105/lisp.h b/test/test0105/lisp.h index b2dd5bf..fb8acc0 100644 --- a/test/test0105/lisp.h +++ b/test/test0105/lisp.h @@ -63,7 +63,6 @@ struct cell* make_cons(struct cell* a, struct cell* b); int numerate_string(char *a); char* numerate_number(int a); int match(char* a, char* b); -void file_print(char* s, FILE* f); /* Global objects */ struct cell *all_symbols; diff --git a/test/test0105/lisp_cell.c b/test/test0105/lisp_cell.c index ed58ae3..2cee0ac 100644 --- a/test/test0105/lisp_cell.c +++ b/test/test0105/lisp_cell.c @@ -190,7 +190,7 @@ struct cell* pop_cons() { if(NULL == free_cells) { - file_print("OOOPS we ran out of cells", stderr); + fputs("OOOPS we ran out of cells", stderr); exit(EXIT_FAILURE); } struct cell* i; diff --git a/test/test0105/lisp_eval.c b/test/test0105/lisp_eval.c index bb9b7de..f4a34f7 100644 --- a/test/test0105/lisp_eval.c +++ b/test/test0105/lisp_eval.c @@ -114,7 +114,7 @@ struct cell* apply(struct cell* proc, struct cell* vals) } else { - file_print("Bad argument to apply\n", stderr); + fputs("Bad argument to apply\n", stderr); exit(EXIT_FAILURE); } return temp; @@ -168,8 +168,8 @@ struct cell* process_sym(struct cell* exp, struct cell* env) struct cell* tmp = assoc(exp, env); if(tmp == nil) { - file_print("Unbound symbol:", stderr); - file_print(exp->string, stderr); + fputs("Unbound symbol:", stderr); + fputs(exp->string, stderr); fputc('\n', stderr); exit(EXIT_FAILURE); } @@ -287,7 +287,7 @@ struct cell* prim_mod(struct cell* args) int mod = args->car->value % args->cdr->car->value; if(nil != args->cdr->cdr) { - file_print("wrong number of arguments to mod\n", stderr); + fputs("wrong number of arguments to mod\n", stderr); exit(EXIT_FAILURE); } return make_int(mod); @@ -432,7 +432,7 @@ struct cell* prim_output(struct cell* args, FILE* out) { if(INT == args->car->type) { - file_print(numerate_number(args->car->value), out); + fputs(numerate_number(args->car->value), out); } else if(CHAR == args->car->type) { @@ -444,7 +444,7 @@ struct cell* prim_output(struct cell* args, FILE* out) } else { - file_print(args->car->string, out); + fputs(args->car->string, out); } } return tee; @@ -479,8 +479,8 @@ struct cell* prim_freecell(struct cell* args) { if(nil == args) { - file_print("Remaining Cells: ", stdout); - file_print(numerate_number(left_to_take), stdout); + fputs("Remaining Cells: ", stdout); + fputs(numerate_number(left_to_take), stdout); return nil; } return make_int(left_to_take); diff --git a/test/test0105/lisp_print.c b/test/test0105/lisp_print.c index 7db570c..6a4026d 100644 --- a/test/test0105/lisp_print.c +++ b/test/test0105/lisp_print.c @@ -23,7 +23,7 @@ void writeobj(FILE *output_file, struct cell* op) if(INT == op->type) { - file_print(numerate_number(op->value), output_file); + fputs(numerate_number(op->value), output_file); } else if(CONS == op->type) { @@ -39,7 +39,7 @@ void writeobj(FILE *output_file, struct cell* op) op = op->cdr; if(op->type != CONS) { - file_print(" . ", output_file); + fputs(" . ", output_file); writeobj(output_file, op); fputc(')', output_file); break; @@ -49,15 +49,15 @@ void writeobj(FILE *output_file, struct cell* op) } else if(SYM == op->type) { - file_print(op->string, output_file); + fputs(op->string, output_file); } else if(PRIMOP == op->type) { - file_print("#", output_file); + fputs("#", output_file); } else if(PROC == op->type) { - file_print("#", output_file); + fputs("#", output_file); } else if(CHAR == op->type) { @@ -65,13 +65,13 @@ void writeobj(FILE *output_file, struct cell* op) } else if(STRING == op->type) { - file_print(op->string, output_file); + fputs(op->string, output_file); } else { - file_print("Type ", stderr); - file_print(numerate_number(op->type), stderr); - file_print(" is unknown\nPrint aborting hard\n", stderr); + fputs("Type ", stderr); + fputs(numerate_number(op->type), stderr); + fputs(" is unknown\nPrint aborting hard\n", stderr); exit(EXIT_FAILURE); } } diff --git a/test/test0105/run_test.sh b/test/test0105/run_test.sh index 48cb56e..30003f9 100755 --- a/test/test0105/run_test.sh +++ b/test/test0105/run_test.sh @@ -35,7 +35,6 @@ mkdir -p ${TMPDIR} -f functions/in_set.c \ -f functions/numerate_number.c \ -f functions/match.c \ - -f functions/file_print.c \ -f test/test0105/lisp.c \ -f test/test0105/lisp_cell.c \ -f test/test0105/lisp_eval.c \ diff --git a/test/test1000/hello-aarch64.sh b/test/test1000/hello-aarch64.sh index 4578bc7..68579f3 100755 --- a/test/test1000/hello-aarch64.sh +++ b/test/test1000/hello-aarch64.sh @@ -28,7 +28,6 @@ mkdir -p ${TMPDIR} -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ - -f functions/file_print.c \ -f functions/number_pack.c \ -f functions/string.c \ -f functions/require.c \ @@ -87,7 +86,6 @@ then -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ - -f functions/file_print.c \ -f functions/number_pack.c \ -f functions/string.c \ -f functions/require.c \ diff --git a/test/test1000/hello-amd64.sh b/test/test1000/hello-amd64.sh index dad2dcb..0c13f8b 100755 --- a/test/test1000/hello-amd64.sh +++ b/test/test1000/hello-amd64.sh @@ -28,7 +28,6 @@ mkdir -p ${TMPDIR} -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ - -f functions/file_print.c \ -f functions/number_pack.c \ -f functions/string.c \ -f functions/require.c \ @@ -87,7 +86,6 @@ then -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ - -f functions/file_print.c \ -f functions/number_pack.c \ -f functions/string.c \ -f functions/require.c \ diff --git a/test/test1000/hello-armv7l.sh b/test/test1000/hello-armv7l.sh index fe36ff4..de83b2b 100755 --- a/test/test1000/hello-armv7l.sh +++ b/test/test1000/hello-armv7l.sh @@ -28,7 +28,6 @@ mkdir -p ${TMPDIR} -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ - -f functions/file_print.c \ -f functions/number_pack.c \ -f functions/string.c \ -f functions/require.c \ @@ -86,7 +85,6 @@ then -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ - -f functions/file_print.c \ -f functions/number_pack.c \ -f functions/string.c \ -f functions/require.c \ diff --git a/test/test1000/hello-knight-posix.sh b/test/test1000/hello-knight-posix.sh index a29cf36..f9007f4 100755 --- a/test/test1000/hello-knight-posix.sh +++ b/test/test1000/hello-knight-posix.sh @@ -28,7 +28,6 @@ mkdir -p ${TMPDIR} -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ - -f functions/file_print.c \ -f functions/number_pack.c \ -f functions/string.c \ -f functions/require.c \ @@ -79,7 +78,6 @@ then -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ - -f functions/file_print.c \ -f functions/number_pack.c \ -f functions/string.c \ -f functions/require.c \ @@ -116,7 +114,6 @@ then -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ - -f functions/file_print.c \ -f functions/number_pack.c \ -f functions/string.c \ -f functions/require.c \ diff --git a/test/test1000/hello-x86.sh b/test/test1000/hello-x86.sh index a75c728..ad79399 100755 --- a/test/test1000/hello-x86.sh +++ b/test/test1000/hello-x86.sh @@ -28,7 +28,6 @@ mkdir -p ${TMPDIR} -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ - -f functions/file_print.c \ -f functions/number_pack.c \ -f functions/string.c \ -f functions/require.c \ @@ -86,7 +85,6 @@ then -f functions/match.c \ -f functions/in_set.c \ -f functions/numerate_number.c \ - -f functions/file_print.c \ -f functions/number_pack.c \ -f functions/string.c \ -f functions/require.c \ diff --git a/test/test1000/proof.answer b/test/test1000/proof.answer index ac8b3f4..86ded36 100644 --- a/test/test1000/proof.answer +++ b/test/test1000/proof.answer @@ -1 +1 @@ -ae128f5f8bccb797af45fc65f730a945dab92d6aa7bb54b31f54b1c0693be8d2 test/test1000/proof +c01c25c493655094e8fd89ff7a7e895e89046386ff38733df0a9a70822c22c94 test/test1000/proof