Why S32DS compiler can't recognize MARCO

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Why S32DS compiler can't recognize MARCO

666 Views
alexhuang5367
Contributor II

hello dear all

i'v try to use MARCO function in S32DS like this

#ifndef max
#define max(a,b) (((a) > (b)) ? (a) : (b))
#endif

#ifndef min
#define min(a,b) (((a) < (b)) ? (a) : (b))
#endif

but it shows some error like this, how can i solve it?

marco_error.JPG

Tags (2)
0 Kudos
1 Reply

558 Views
stanish
NXP Employee
NXP Employee

Hi Alex,

I don't see anything suspicious on the screenshot you attached.

Could you possibly post the C statement at line 182?

I'd recommend you to preprocess the main.c - perhaps this gives you more info about the macro usage.

pastedImage_1.png

Stan

0 Kudos