mersenneforum.org  

Go Back   mersenneforum.org > Extra Stuff > Programming

Reply
 
Thread Tools
Old 2011-03-05, 20:56   #1
tichy
 
Nov 2010

22×19 Posts
Default macros in nasm

Hi,

I'm trying to get to compile with NASM a piece of code like this:
Code:
%define IFNDEF %ifndef
%define ENDIF %endif

IFNDEF foo
;bar
ENDIF
nasm -E shows:
Code:
%line 3+1 test.mac

%ifndef foo

%endif
what is basicaly what I want to achive (and in this form it compiles), but when I attempt compilation just invoking nasm I get:
Code:
test.mac:4: error: label or instruction expected at start of line
test.mac:6: error: label or instruction expected at start of line
I'm probably doing sth wrong, any thoughts ?

Last fiddled with by tichy on 2011-03-05 at 20:58
tichy is offline   Reply With Quote
Old 2011-03-06, 16:24   #2
tichy
 
Nov 2010

22×19 Posts
Default

Closed - I got it solved.
tichy is offline   Reply With Quote
Reply

Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
GNU specific macros R.D. Silverman Programming 17 2015-09-29 03:44
List of nvcc compiler macros? ewmayer GPU Computing 8 2013-10-13 00:46

All times are UTC. The time now is 07:46.


Wed Dec 8 07:46:34 UTC 2021 up 138 days, 2:15, 1 user, load averages: 1.55, 1.59, 1.60

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.

This forum has received and complied with 0 (zero) government requests for information.

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation.
A copy of the license is included in the FAQ.