Closed rofl0r closed 4 years ago
What is the suffix of the files you are trying to process? Currently lacc will only recognize .c and .i as containing source code, but that is of course not necessarily correct. I need to find a better heuristic here to determine which files are meant for the linker and which are supposed to be processed.
The preprocessor should be very easy to extract from the rest, if you want to. Take a look at src/preprocessor/preprocess.c#L676, where only the preprocessor part is invoked in order to produce preprocessed output.
thanks! although meanwhile i'm almost finished writing my own ;) i was trying with -E (so i suppose this should turn off filetype detection)
I did some changes to improve language detection, and also have to option to explicitly set the input language with -x.
i'm evaluating a bunch of C preprocessor sources for usage as macro assembler in custom assembly files. when i try lacc on such a file (which is perfectly fine preprocessed by e.g. GCC's cpp) i get "Unrecognized input files.". btw, would it be hard to unwire the preprocessor code from the rest ?