1
0
mirror of https://gitlab.com/camelot/kickc.git synced 2024-06-03 07:29:37 +00:00
kickc/src/test/kc/library/printf/printf_lib.c
Sven Van de Velde e371d304f6 - Fixed test cases. Full retest of all test cases.
- Create the possibility of forward declaration of structs as part of the language.
- Generation of forward declarations in the .asm header files.
- Treat global variables as part of global memory, even in libraries. Ensure that globals are not overwritten when importing.
- Ensure that the various compilation models (stack, var, phi) in combination with the memory models (zp, mem) result in proper execution of code and proper memory allocation etc, etc.
- Added the lru-cache logic to properly test the compilation and memory model combinations. (A lot of bugfixes as a result!)
2024-01-16 08:06:14 +03:00

30 lines
878 B
C

#pragma encoding(screencode_mixed)
#pragma var_model(mem)
#pragma struct_model(classic) // This is important or kickc messes up the parameters ...
#pragma asm_library
#pragma calling(__varcall)
#pragma asm_export(clrscr)
#pragma asm_export(gotoxy)
#pragma asm_export(wherex, wherey)
#pragma asm_export(screensize, screensizex, screensizey, cputln )
#pragma asm_export(cputcxy, cputs, cputsxy, textcolor, bgcolor, bordercolor )
#pragma asm_export(kbhit, cursor, scroll )
#pragma asm_export(screenlayer1, screenlayer2)
#pragma asm_export(cpeekc, cpeekcxy)
#pragma calling(__varcall)
#pragma asm_export(printf_str)
#pragma asm_export(printf_uint, printf_sint)
#pragma asm_export(printf_ulong, printf_slong)
#pragma asm_export(printf_uchar, printf_schar)
#pragma calling(__stackcall)
#pragma asm_export(cputc)
#pragma calling(__varcall)
#include <conio.h>
#include <printf.h>