[gccsdk] [Bug 210] New: cmunge & gcc 4.6: continuation character gets lost or not taken into account

bugzilla-daemon at riscos.info bugzilla-daemon at riscos.info
Thu Sep 16 17:57:16 PDT 2010


http://www.riscos.info/bugzilla3/show_bug.cgi?id=210

           Summary: cmunge & gcc 4.6: continuation character gets lost or
                    not taken into account
           Product: GCC/GCCSDK
           Version: other
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P1
         Component: RISC OS-specific tools
        AssignedTo: John.Tytgat at aaug.net
        ReportedBy: John.Tytgat at aaug.net
   Estimated Hours: 0.0


Created an attachment (id=78)
 --> (http://www.riscos.info/bugzilla3/attachment.cgi?id=78)
Example CMHG file (from GDBServer)

E.g.:

--8<--
error_identifiers: \
    kErr_Error1("Error1") \
    kErr_Error2("Error2") \
    kErr_Error3("Error3")
--8<--

gcc 4.6.0 (20100915 (experimental) [trunk revision 164317]) preprocessor
transforms this into:

--8<--
# 1 "test-preprocess.c"
# 1 "<built-in>"
# 1 "<command-line>"
# 1 "test-preprocess.c"
error_identifiers:
 kErr_Error1("Error1")
 kErr_Error2("Error2")
 kErr_Error3("Error3")
--8<--

I.e. the continuation characters got lost.  cmunge will complain with:

--8<--
Serious Error: Field names should be of the form <field>: [<value>]
               at ..., line ...
--8<--

While gcc 4.1.2 preprocessor transforms this into:

--8<--
# 1 "test-preprocess.c"
# 1 "<built-in>"
# 1 "<command-line>"
# 1 "test-preprocess.c"
error_identifiers: kErr_Error1("Error1") kErr_Error2("Error2")
kErr_Error3("Error3")
--8<--

and this is works fine with cmunge.  Note however, that if you do not use the
preprocessor with cmunge (i.e. no -p option), above still fails so it is *not*
a preprocessor issue but something which got worse (i.e. more exposed) with the
gcc 4.6 as preprocessor.

It looks like cmunge first needs to resolve the continuation character, then
invoke the preprocessor and finally parse the result as CMHG syntax.

-- 
Configure bugmail: http://www.riscos.info/bugzilla3/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.




More information about the gcc mailing list