-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Allow macros with arguments + 30cc can now compile its lexer.c! (…
…#50) * macro args * Accumulate preprocessor result in a linkedlist * Stringify macro * Testing preprocessed outputs * Refactor * next version of preprocessor? * Fix * Assume newline in begin * Remove extern/size when declared func is defined * Organize preprocessor * Organize preprocessor * Compare according to size * fix: Lexer worksgit statusgit status * More stuff * Remove preprocessor tests
- Loading branch information
Showing
62 changed files
with
6,233 additions
and
1,304 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
void printf(char *, ...); | ||
|
||
#define ADD(x, y) (20 + 2 * x + 3 * y) | ||
#define STR(x) #x | ||
|
||
int main() | ||
{ | ||
int a = 10; | ||
int cde = ADD(a, 20); | ||
char *s = STR(cde); | ||
printf("%s: %d\n", s, cde); | ||
} |
Oops, something went wrong.