flat assembler
Message board for the users of flat assembler.
Index
> Compiler Internals > A preprocessor bug: local affected by an unrelated backslash |
Author |
|
revolution 30 Dec 2014, 16:31
Indeed, using Egyptian brackets gives a different result
Code: rept 1 { macro m \{ local l display \`l,13,10 \} } m m |
|||
30 Dec 2014, 16:31 |
|
evk1 30 Dec 2014, 16:38
Try using backslashes with such keywords. \local \common.
_________________ Sorry for my English |
|||
30 Dec 2014, 16:38 |
|
Tomasz Grysztar 30 Dec 2014, 16:41
The special directives processed by macro line maker are only recognized if they are the first symbol in line (another detail probably not mentioned in the manual), otherwise they are treated as just another symbol preprocessed in a standard way. For example:
Code: macro m { l: common } Code: macro m common { common l: common } m dd l And "{" is nothing special from the point of view of line maker, it is just another symbol that gets in the way. |
|||
30 Dec 2014, 16:41 |
|
l_inc 30 Dec 2014, 17:01
revolution
Quote: revolution says: I moved it for you l_inc says: Thank you. Tomasz Grysztar Oh... I suppose, I overhurried to report on this one. Sorry. _________________ Faith is a superposition of knowledge and fallacy |
|||
30 Dec 2014, 17:01 |
|
baldr 31 Dec 2014, 08:39
Tomasz Grysztar,
Probably implicit line-break after opening brace would do (heh, closing brace have it). |
|||
31 Dec 2014, 08:39 |
|
l_inc 31 Dec 2014, 13:10
baldr
Quote: heh, closing brace have it I don't think there's any special handling of the closing brace, cause the following doesn't work either: Code: macro m [a] { rept 1 \{\} common display a,13,10 } m 'a','b' It's just about the moment when the corresponding directive appears as the first token on a line. _________________ Faith is a superposition of knowledge and fallacy |
|||
31 Dec 2014, 13:10 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.