Welcome, Guest. Please login or register.

Author Topic: 2 ISO C 16.3.3/3 or previous, informations needed  (Read 1965 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline JoseTopic starter

  • Hero Member
  • *****
  • Join Date: Feb 2002
  • Posts: 2869
    • Show all replies
2 ISO C 16.3.3/3 or previous, informations needed
« on: May 04, 2007, 04:36:52 PM »
Hi. Seems that even the ISO C standards are commercial, most google searches give me links to places selling it :-x
I got the essential part of the macros I'm doing working:) But  I really need to know 2 things wich are essential to make them compatible with most compilers as some behave differently and have diferent limits.
1- What's the maximum macro argument nesting limit for preprocessor macro calls(i.e. MACROA(MACROB(MACROC(args))) )?
2- What's the maximum line lenght ?

I remember reading that the official limit for nested structs was 8 on iso 89 I think, so there must also be some official limit for the preprocessor.

Cheers
José
\\"We made Amiga, they {bleep}ed it up\\"
 

Offline JoseTopic starter

  • Hero Member
  • *****
  • Join Date: Feb 2002
  • Posts: 2869
    • Show all replies
Re: 2 ISO C 16.3.3/3 or previous, informations needed
« Reply #1 on: May 04, 2007, 05:28:58 PM »
From what I've see so far, documentation about the preprocessor is completely scarce in C books.
The ISO specs are much more specific, I've seen a few posts on GCC mailing lists about allowed tokens in concatenations, for example, all referencing ISO docs.
SASC seems to be very limitative on this. A nest of 32 macros like the above makes it report an internal error. VBCC and Borland(X86 8-) ) seem to be less limitative, though I haven't tested them to extremes.

Basically I need a limit to settle down to.
\\"We made Amiga, they {bleep}ed it up\\"
 

Offline JoseTopic starter

  • Hero Member
  • *****
  • Join Date: Feb 2002
  • Posts: 2869
    • Show all replies
Re: 2 ISO C 16.3.3/3 or previous, informations needed
« Reply #2 on: May 05, 2007, 04:55:50 PM »
"...just checked it all"

Thanks for your time.
Gonna try to make a selfexpanding thing in layers :lol:
\\"We made Amiga, they {bleep}ed it up\\"