flat assembler
Message board for the users of flat assembler.
Index
> Macroinstructions > [DONE] function(params) -> invoke function,params |
Author |
|
dead_body 20 Dec 2006, 22:13
this is a demonstrate of fasm preprocessor power
ther are two files. one file have macroses to change syntax, second file contains the names of functions. this macroses only replace some part of string. for example: Code: ;first declare it: hllToFuncProcEx my_func:invoke ;and then you can use it: my_func(param1,param2) ;and these macroses will change this string to: invoke my_func,<param1>,<param2> or something else: Code: hllToFuncProcEx text.write:libcall ;use it! text.write(stream.stdout,\<"test string",10\>) ;it will be: libcall text.write,<stream.stdout>,\<"test string",10\> why in last example \< needed see this topic: http://board.flatassembler.net/topic.php?t=6293 nesting is supported. example: Code: hllToFuncProcEx my_func1:invoke,my_func2:stdcall,my_func3:my_call_function my_func1(my_func2(1,<"test",13,10>,my_func3()),my_func3(argument1)) ;will be like next: invoke my_func1,<stdcall my_func2,<1>,<'test',13,10>,<my_call_function my_func3>>,<my_call_function my_func3,<argument1>>
|
|||||||||||
20 Dec 2006, 22:13 |
|
vid 20 Dec 2006, 23:58
i have own version of pushd used with libcall
Wouldn't it work by fixing ( and ) to <> just inside processing macro, and then fix them back? |
|||
20 Dec 2006, 23:58 |
|
dead_body 21 Dec 2006, 07:36
Quote: What do you think? unusual, but interesting. this officially? |
|||
21 Dec 2006, 07:36 |
|
Tomasz Grysztar 21 Dec 2006, 07:42
Not, it's not official. Just an interesting thought about simulating D syntax.
|
|||
21 Dec 2006, 07:42 |
|
Raedwulf 21 Dec 2006, 10:59
Very pretty
|
|||
21 Dec 2006, 10:59 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.