Closed mattconway1984 closed 8 months ago
If you're using Ceedling, just enable preprocessing in the project file. If you're not, it's your responsibility to call the preprocessor before calling CMock. CMock just operates on whatever you give it. While someday we'd love to have it a fullblown C parser, it's not at this point... it just handles the majority of cases and leaves odd corner cases as tasks for the developer to figure out how to preprocess.
Take for example:
Then guess what happens.....
void Foo_CMockExpectAndReturn(UNITY_LINE_TYPE cmock_line, char *x, INLINE void cmock_to_return)
Why does Cmock not attempt to pre-process the file before mock generation?