flat assembler
Message board for the users of flat assembler.

Index > Main > Compilation abort

Author
Thread Post new topic Reply to topic
CodeX



Joined: 08 Feb 2006
Posts: 20
Location: Estonia
CodeX 16 Feb 2006, 16:22
Hello!

If somebody could help me with this?

Is there a way to stop FASM compiling process with custom error message?

I made a program where all symbolic constants which correspond to program parameters are contained in separate configuration file. I need a way to validate these configuration parameters during compilation time and stop compilation with corresponding error message if some parameters are not valid.
In the FAsm documentation I've found a "display" directive, which can help me with message showing, but what about compilation abort?
Post 16 Feb 2006, 16:22
View user's profile Send private message Reply with quote
Tomasz Grysztar



Joined: 16 Jun 2003
Posts: 8359
Location: Kraków, Poland
Tomasz Grysztar 16 Feb 2006, 16:30
Post 16 Feb 2006, 16:30
View user's profile Send private message Visit poster's website Reply with quote
CodeX



Joined: 08 Feb 2006
Posts: 20
Location: Estonia
CodeX 17 Feb 2006, 10:21
Ok. I see. It's just too complicated to add this feature in FASM.
Anyway, thank you for quick answer.
Post 17 Feb 2006, 10:21
View user's profile Send private message Reply with quote
Tomasz Grysztar



Joined: 16 Jun 2003
Posts: 8359
Location: Kraków, Poland
Tomasz Grysztar 17 Feb 2006, 13:25
In short, it reduces to the problem that three different types of such stopping would be needed. The "preprocessor halt", "strong assembler halt" and "weak assembler halt". First one for aborting the compilation during the preprocessing (currently achieved for example with making invalid syntax of macro, like "macro+"). Second one for aborting the compilation as soon as the assembler hits that place (currently achieved with invalid instruction, like "err"). The last one is to halt the assembler only when the error persist while the rest of the code is being resolved correctly (currently it may achieved with things like negative counts for repeating directives, like "rb -1"). The last one would be needed for example when the condition under which the error would happen depended on the values that have to be resolved, look here for some information: http://board.flatassembler.net/topic.php?t=3805
Post 17 Feb 2006, 13:25
View user's profile Send private message Visit poster's website Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.