buglwIP - A Lightweight TCP/IP stack - Bugs: bug #35874, reserved identifier violation

 
 

You are not allowed to post comments on this tracker with your current authentification level.

bug #35874: reserved identifier violation

Submitted by:  Markus Elfring <elfring>
Submitted on:  Sat 17 Mar 2012 02:40:19 PM UTC  
 
Category: NoneSeverity: 3 - Normal
Item Group: Change RequestStatus: None
Privacy: PublicAssigned to: None
Open/Closed: OpenPlanned Release: 1.5.0
lwIP version: 1.4.0

Tue 27 Mar 2012 05:51:39 PM UTC, comment #4:

Being like that, I'd target this for 1.5.0 (not that high prio to me, or did you have actual problems with the identifiers as they are now?).

Working on it, I'd love to restructure all defines to begin with "LWIP_" to prevent possible future portability problems.

Simon Goldschmidt <goldsimon>
Project Administrator
Sun 18 Mar 2012 09:15:38 PM UTC, comment #3:

Re Simon's comment about C++ and C99 standards, it is worth pointing out that identifiers beginning with double underscore or underscore followed by an uppercase letter are also reserved by the ANSI/ISO C-1990 standard (see section 7.1.3), which is the basis of most embedded C compilers. This is not a new restriction in C99.

David Empson <dempson>
Sun 18 Mar 2012 04:53:44 PM UTC, comment #2:

Would you like to integrate the appended adjustments into your source code repository?

(file #25394, file #25395)

Markus Elfring <elfring>
Sun 18 Mar 2012 12:33:48 PM UTC, comment #1:

I don't really know if the cited standards (C++, C99) apply to us as lwIP does not use C++ and most embedded compilers no nothing about C99, however, I guess it wouldn't hurt to change these identifiers...

Would you mind creating a patch against git master?

Simon Goldschmidt <goldsimon>
Project Administrator
Sat 17 Mar 2012 02:40:19 PM UTC, original submission:

I suggest to try the search pattern "\<_(?:(?:_(.*))|([A-Z]+))" on source files.
Some places will be found where names begin with two underscores or an underscore and an uppercase letter.

Examples:

This usage does not fit to the expected naming conventions of the C/C++ language standard.
I recommend to adjust your selection for unique names.

Markus Elfring <elfring>

 

Attached Files

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by dempson (Posted a comment)
  • -unavailable- added by goldsimon (Posted a comment)
  • -unavailable- added by elfring (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 3 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Tue 27 Mar 2012 05:51:39 PM UTCgoldsimonPlanned Release=>1.5.0
    Sun 18 Mar 2012 04:53:44 PM UTCelfringAttached File-=>Added 0001-Bug-35874-Make-a-configuration-symbol-standard-compl.patch, #25394
      Attached File-=>Added 0001-Bug-35874-Make-include-guards-standard-compliant.patch, #25395

    Back to the top


    Powered by Savane 3.1-cleanup