Talk:Compiler/Simple file inclusion pre processor: Difference between revisions

(Two preprocessor tasks)
Line 40:
:::Also, I doubt that a C pre-processor written in anything but C would get much use for anything other than bootstrapping... --[[User:Tigerofdarkness|Tigerofdarkness]] ([[User talk:Tigerofdarkness|talk]]) 21:42, 6 June 2021 (UTC)
I believe our sample language could use one line: #include "file" and #define call value. Usage could be:
 
~~ Header.h ~~
#define area(h, w) h*w
Line 50 ⟶ 51:
 
yielding code output of:
 
area = 6*5;
 
Or:
 
/* Include Header.h */
/* Define area(h, w) as h*w */