Share

The Netwide Assembler

Subscribe

Delegating %undef

  1. 2009-11-12 13:47:03 UTC

    How can I delegate %undef?

    In the example below the assembler (called with "nasm.exe -t -f rdf q.asm") bemoans my code, displays

    "q.asm:19: error: interminable macro recursion"

    and hangs.

    ===q.asm===

    
    bits 32
    CPU P4

    %macro my_def 2 %xdefine %1 esp+%2 %endmacro

    %macro my_undef 1 %undef %1 %endmacro

    global checkit checkit: mydef x,4 mov eax,[x] myundef x

    mydef x,8 add eax,[x] myundef x ret

    What is the preferred way to do this?

    Thanks,

    Jasper

  2. 2009-11-29 22:09:57 UTC

    ... and hangs. ...

    It'll not hang anymore. Fixed. Meanwhile such a style not supported yet.

    See comments on commit http://repo.or.cz/w/nasm.git/commit/bd38c8f231d938ffdf0916809bf2a6b65e62ea61

    Thanks for report. If you find something strange like "hang", "crash" or whatever -- do not hesitate to file a bug report on tracker :)

< Previous | 1 | Next >

Add a Reply

You can use Markdown syntax in your reply.

Preview

Monitor this

Log in to monitor this topic. Not registered? Create an account to receive email updates when replies are posted to this topic. If you do not log in or register, your reply will be added anonymously.