shinh / elvm

EsoLangVM Compiler Infrastructure
MIT License
1.13k stars 143 forks source link

Use inttypes for printing uint64_t #84

Closed ooxi closed 4 years ago

ooxi commented 4 years ago

GenLabelStatic assumes uint64_t can be printed using %l which causes an error on platforms where this assumtion does not hold

target/wm.c: In function ‘GenLabelStatic’:
target/wm.c:1461:26: error: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 6 has type ‘uint64_t {aka long long unsigned int}’ [-Werror=format=]
                  "%s_%0*lx",
                      ~~~~^
                      %0*llx
ooxi commented 4 years ago

Breaks self hosting, will update pull request