[Bug c++/55776] -Wshadow generates an incorrect warning with enum classes

2020-09-17 Thread ian.s.mcinerney at ieee dot org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55776 Ian McInerney changed: What|Removed |Added CC||ian.s.mcinerney at ieee dot org --- Comm

[Bug c++/55776] -Wshadow generates an incorrect warning with enum classes

2016-01-15 Thread Predelnik at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55776 Sergey Semushin changed: What|Removed |Added CC||Predelnik at gmail dot com --- Comment

[Bug c++/55776] -Wshadow generates an incorrect warning with enum classes

2013-06-05 Thread manu at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55776 --- Comment #7 from Manuel López-Ibáñez --- (In reply to Jonathan Wakely from comment #5) > A better example: > > typedef unsigned char foo; > > enum class myenum > { > foo, > bar = (foo)-1 > }; > > Is the value -1L or 255? > > If I rename

[Bug c++/55776] -Wshadow generates an incorrect warning with enum classes

2013-06-04 Thread redi at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55776 --- Comment #6 from Jonathan Wakely --- It also changes meaning if I reorder the declarations of myenum::foo and myenum::bar, which is exactly the sort of fragile code that deserves a warning.

[Bug c++/55776] -Wshadow generates an incorrect warning with enum classes

2013-06-04 Thread redi at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55776 --- Comment #5 from Jonathan Wakely --- A better example: typedef unsigned char foo; enum class myenum { foo, bar = (foo)-1 }; Is the value -1L or 255? If I rename myenum::foo to myenum::Foo the code silently changes meaning.

[Bug c++/55776] -Wshadow generates an incorrect warning with enum classes

2013-06-04 Thread redi at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55776 --- Comment #4 from Jonathan Wakely --- (In reply to Manuel López-Ibáñez from comment #3) > But the global foo is a type while myenum::foo is not a type. Is there any > context where they can be used interchangeably? > > enum class myenum > { >

[Bug c++/55776] -Wshadow generates an incorrect warning with enum classes

2013-06-04 Thread manu at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55776 Manuel López-Ibáñez changed: What|Removed |Added CC||manu at gcc dot gnu.org --- Comment

[Bug c++/55776] -Wshadow generates an incorrect warning with enum classes

2013-06-04 Thread jason at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55776 Jason Merrill changed: What|Removed |Added CC||jason at gcc dot gnu.org --- Comment #2 f

[Bug c++/55776] -Wshadow generates an incorrect warning with enum classes

2013-05-31 Thread s...@s-e-f-i.de
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55776 Philipp changed: What|Removed |Added CC||jason at redhat dot com --- Comment #1 from Phi