[erlang-questions] macro - newbie question

Balathasan Sayanthan bsayanthan@REDACTED
Thu Apr 3 05:04:59 CEST 2008


Thank you,

I am sorry it was a silly mistake and it was indeed a misplaced semicolon.

On Wed, Apr 2, 2008 at 9:28 PM, Hasan Veldstra <hasan.veldstra@REDACTED>
wrote:

> -define(OP_NAME(OpId),
> >        if
> > ...............
> > ...............
> >        end).
> >
> >
> > when I try to compile the  i get an error
> > ./trial.erl:7: syntax error before: 'end'
> > ./trial.erl:3: function getval/1 undefined
> >
> > Please let me know how I should use macros in this way.
> >
>
> There's a syntax error somewhere between 'if' and 'end' in your macro
> definition, can't tell more without the source. Quite likely to be a
> misplaced semi-colon though...
>



-- 
Balathasan Sayanthan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20080403/5c4d3f93/attachment.htm>


More information about the erlang-questions mailing list