public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug ada/46601] New: Getting compilation error with GCC 4.2.0 for including the header file "<map>"
@ 2010-11-22 12:33 asha328 at gmail dot com
  2010-11-22 12:50 ` [Bug c++/46601] " rguenth at gcc dot gnu.org
  0 siblings, 1 reply; 2+ messages in thread
From: asha328 at gmail dot com @ 2010-11-22 12:33 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46601

           Summary: Getting compilation error with GCC 4.2.0 for including
                    the header file "<map>"
           Product: gcc
           Version: 4.2.0
            Status: UNCONFIRMED
          Severity: blocker
          Priority: P3
         Component: ada
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: asha328@gmail.com


Here goes the error description:

NOTE: This worked with version(3.4.6)
----------------------------------------------------

/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:226:56:
error: macro "min" passed 3 arguments, but takes just 2
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:246:56:
error: macro "max" passed 3 arguments, but takes just 2
In file included from
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_tree.h:67,
                 from
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/map:65,


/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:182:
error: expected unqualified-id before 'const'
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:182:
error: expected `)' before 'const'
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:182:
error: expected `)' before 'const'
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:182:
error: expected `)' before 'const'
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:182:
error: expected initializer before 'const'
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:204:
error: expected unqualified-id before 'const'
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:204:
error: expected `)' before 'const'
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:204:
error: expected `)' before 'const'
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:204:
error: expected `)' before 'const'
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:204:
error: expected initializer before 'const'
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:226:
error: function definition does not declare parameters
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:246:
error: function definition does not declare parameters
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:
In function 'bool std::lexicographical_compare(const unsigned char*, const
unsigned char*, const unsigned char*, const unsigned char*)':
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:909:
error: expected unqualified-id before '(' token


^ permalink raw reply	[flat|nested] 2+ messages in thread

* [Bug c++/46601] Getting compilation error with GCC 4.2.0 for including the header file "<map>"
  2010-11-22 12:33 [Bug ada/46601] New: Getting compilation error with GCC 4.2.0 for including the header file "<map>" asha328 at gmail dot com
@ 2010-11-22 12:50 ` rguenth at gcc dot gnu.org
  0 siblings, 0 replies; 2+ messages in thread
From: rguenth at gcc dot gnu.org @ 2010-11-22 12:50 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46601

Richard Guenther <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |INVALID

--- Comment #1 from Richard Guenther <rguenth at gcc dot gnu.org> 2010-11-22 12:46:33 UTC ---
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:226:56:
error: macro "min" passed 3 arguments, but takes just 2
/vobs/gnu/gcc/SunOS-5.8/lib/gcc/sparc-sun-solaris2.8/4.2.0/../../../../include/c++/4.2.0/bits/stl_algobase.h:246:56:
error: macro "max" passed 3 arguments, but takes just 2
In file included from

something defines a macro named min and max, that conflicts with std::min
and std::max.

Do not include C headers.

Btw, 4.2.0 is no longer supported, please update to at least 4.3.5 which
may contain a workaround.


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-11-22 12:46 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-11-22 12:33 [Bug ada/46601] New: Getting compilation error with GCC 4.2.0 for including the header file "<map>" asha328 at gmail dot com
2010-11-22 12:50 ` [Bug c++/46601] " rguenth at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).