public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/11946] New: fun and merriment with enums as function arguments
@ 2003-08-16 13:54 richard dot kreckel at ginac dot de
  2003-08-16 14:08 ` [Bug c++/11946] " pinskia at gcc dot gnu dot org
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: richard dot kreckel at ginac dot de @ 2003-08-16 13:54 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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

           Summary: fun and merriment with enums as function arguments
           Product: gcc
           Version: 3.4
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: richard dot kreckel at ginac dot de
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu

Consider this piece of code:

#include <iostream>
using namespace std;

enum thing {
    nothing = 0,
    chair = 1,
    desk = 2,
    shelf = 4,
    furniture = chair | desk | shelf
};

bool test1(const thing& t)
{
    if (t & shelf != 0)
	return true;
    return false;
}
bool test2(const thing& t)
{
    if (t & shelf)
	return true;
    return false;
}

int main()
{
    cout << test1( furniture ) << endl;
    cout << test2( furniture ) << endl;
}

Using ss-3.4-20030813 this first prints out "1" (correctly) and then "0"
(wrongly).  Looking at the generated code it becomes apparaent that the if is
completely optimized away in function test2().  This also happens when one
doesn't pass the argument as reference, but as value instead.


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

* [Bug c++/11946] fun and merriment with enums as function arguments
  2003-08-16 13:54 [Bug c++/11946] New: fun and merriment with enums as function arguments richard dot kreckel at ginac dot de
@ 2003-08-16 14:08 ` pinskia at gcc dot gnu dot org
  2003-08-16 14:31 ` [Bug c++/11946] [3.4 regression] " falk at debian dot org
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2003-08-16 14:08 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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


pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |wrong-code


------- Additional Comments From pinskia at gcc dot gnu dot org  2003-08-16 14:08 -------
I do not know what the C++ standard says but there was a change in 3.4 to become more 
standard compliant enum's.  Note C and C++ standards differ in the way they describes enum's.
The C front-end works the way you want it.


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

* [Bug c++/11946] [3.4 regression] fun and merriment with enums as function arguments
  2003-08-16 13:54 [Bug c++/11946] New: fun and merriment with enums as function arguments richard dot kreckel at ginac dot de
  2003-08-16 14:08 ` [Bug c++/11946] " pinskia at gcc dot gnu dot org
@ 2003-08-16 14:31 ` falk at debian dot org
  2003-08-16 21:40 ` richard dot kreckel at ginac dot de
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: falk at debian dot org @ 2003-08-16 14:31 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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


falk at debian dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|normal                      |critical
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|                            |1
            Summary|fun and merriment with enums|[3.4 regression] fun and
                   |as function arguments       |merriment with enums as
                   |                            |function arguments


------- Additional Comments From falk at debian dot org  2003-08-16 14:31 -------
This is clearly a bug. Consider this stripped test case:

void abort();
int main()
{
    enum { shelf = 4 } t = shelf;
    if (!(t & shelf))
	abort ();
}

Note test1 in the original test case is bogus, t & shelf != 0 means t & (shelf
!= 0), i.e., t & chair.


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

* [Bug c++/11946] [3.4 regression] fun and merriment with enums as function arguments
  2003-08-16 13:54 [Bug c++/11946] New: fun and merriment with enums as function arguments richard dot kreckel at ginac dot de
  2003-08-16 14:08 ` [Bug c++/11946] " pinskia at gcc dot gnu dot org
  2003-08-16 14:31 ` [Bug c++/11946] [3.4 regression] " falk at debian dot org
@ 2003-08-16 21:40 ` richard dot kreckel at ginac dot de
  2003-08-17  0:27 ` pinskia at gcc dot gnu dot org
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: richard dot kreckel at ginac dot de @ 2003-08-16 21:40 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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



------- Additional Comments From richard dot kreckel at ginac dot de  2003-08-16 21:40 -------
Yeah, well, and I promise to bang my head against the @#&%! table of C operator
precedences every morning while brushing teeth till I'm deep purple.  Silly me!

Thanks, Falk, for clearing it up.

Anyway, just forget the original test1() and compare the return value of test2()
as compiled with GCC-3.4-pre with the return value of test2() as compiled with
GCC-3.3.1 (which behaves correctly) and see the difference.

So component shouldn't be set to "c++".  What else?  "c"?

embarrassed
        -richy.
-- 
  .''`.  Richard B. Kreckel
 : :' :  <kreckel@debian.org>
 `. `'   <kreckel@ginac.de>
   `-    <http://www.ginac.de/~kreckel/>


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

* [Bug c++/11946] [3.4 regression] fun and merriment with enums as function arguments
  2003-08-16 13:54 [Bug c++/11946] New: fun and merriment with enums as function arguments richard dot kreckel at ginac dot de
                   ` (2 preceding siblings ...)
  2003-08-16 21:40 ` richard dot kreckel at ginac dot de
@ 2003-08-17  0:27 ` pinskia at gcc dot gnu dot org
  2003-08-19 19:03 ` mmitchel at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2003-08-17  0:27 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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



------- Additional Comments From pinskia at gcc dot gnu dot org  2003-08-17 00:27 -------
It should stay c++ as c still works the same way.  There were changes to fix some bugs that most 
likely caused this.


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

* [Bug c++/11946] [3.4 regression] fun and merriment with enums as function arguments
  2003-08-16 13:54 [Bug c++/11946] New: fun and merriment with enums as function arguments richard dot kreckel at ginac dot de
                   ` (3 preceding siblings ...)
  2003-08-17  0:27 ` pinskia at gcc dot gnu dot org
@ 2003-08-19 19:03 ` mmitchel at gcc dot gnu dot org
  2003-08-20  7:07 ` cvs-commit at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2003-08-19 19:03 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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


mmitchel at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |mark at codesourcery dot com
                   |dot org                     |
             Status|NEW                         |ASSIGNED


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

* [Bug c++/11946] [3.4 regression] fun and merriment with enums as function arguments
  2003-08-16 13:54 [Bug c++/11946] New: fun and merriment with enums as function arguments richard dot kreckel at ginac dot de
                   ` (4 preceding siblings ...)
  2003-08-19 19:03 ` mmitchel at gcc dot gnu dot org
@ 2003-08-20  7:07 ` cvs-commit at gcc dot gnu dot org
  2003-08-20  7:12 ` mmitchel at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2003-08-20  7:07 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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



------- Additional Comments From cvs-commit at gcc dot gnu dot org  2003-08-20 07:06 -------
Subject: Bug 11946

CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	mmitchel@gcc.gnu.org	2003-08-20 07:06:47

Modified files:
	gcc            : ChangeLog c-common.c convert.c 
	gcc/config/pa  : pa.h 
	gcc/cp         : ChangeLog class.c cp-tree.h decl.c decl2.c 
	                 name-lookup.c parser.c pt.c typeck2.c 
	gcc/testsuite  : ChangeLog 
	gcc/testsuite/g++.dg/parse: typedef4.C 
	gcc/testsuite/g++.old-deja/g++.robertl: eb133.C eb133a.C 
	                                        eb133b.C 
	gcc/testsuite/gcc.dg: c99-bool-1.c 
Added files:
	gcc/testsuite/g++.dg/expr: enum1.C 
	gcc/testsuite/g++.dg/parse: elab2.C operator4.C 
	gcc/testsuite/g++.dg/template: dtor2.C operator1.C 

Log message:
	PR c++/11946
	* convert.c (convert_to_integer): Use CONVERT_EXPR (instead of
	NOP_EXPR) when necessary.
	* c-common.c (c_common_signed_or_unsigned_type): Correctly handle
	types with precisions other than those given by native machine
	modes.
	
	PR c++/11684
	* cp-tree.h (grok_op_properties): Change prototype.
	* decl.c (grok_op_properties): Add complain parameter.
	(grokfndecl): Pass it.
	* pt.c (tsubst_decl): Adjust accordingly.
	
	PR c++/10926
	* decl.c (start_method): Return immediately if push_template_decl
	does not like the declaration.
	* pt.c (push_template_decl_real): Disallow member template
	destructors.
	
	PR c++/11036.C
	* cp-tree.h (add_binding): Add prototype.
	* class.c (add_method): Set TYPE_HAS_DESTRUCTOR if appropriate.
	(maybe_warn_about_overly_private_class): Use
	CLASSTYPE_DESTRUCTORS.
	(pushclass): Adjust call to set_identifier_type_value.
	* decl.c (add_binding): Give it external linkage.
	(push_local_binding): Adjust call to add_binding.
	(push_class_binding): Likewise.
	(set_identifier_type_value_with_scope): Change prototype.  Use
	add_binding for global bindings.
	(set_identifier_type_value): Adjust accordingly.
	(pushtag): Likewise.
	(pushdecl): Use set_identifier_type_value, not
	set_identifier_type_value_with_scope.
	(pushdecl_namespace_level): Adjust calls to
	SET_IDENTIFIER_TYPE_VALUE to pass a DECL.
	(pushdecl_class_level): Likewise.
	(lookup_tag): Use select_decl.
	(select_decl): Improve comment.
	(record_builtin_type): Do not call pushdecl.
	(cxx_init_decl_processing): Do not call xref_tag for bad_alloc.
	(cp_finish_decl): Adjust call to set_identifier_type_value.
	(check_elaborated_type_specifier): Improve checks for invalid uses
	of typedefs.
	(xref_tag): Adjust call to check_elaborated_type_specifier.
	* decl2.c (grokclassfn): Do not set TYPE_HAS_DESTRUCTOR.
	* name-lookup.c (set_namespace_binding): Use add_binding.
	* parser.c (cp_parser_simple_type_specifier): Return a TYPE_DECL,
	rather than an IDENTIFIER_NODE, to represent built-in types, if
	requested by the caller.
	(cp_parser_postfix_expression): Adjust call.
	(cp_parser_type_specifier): Likewise.
	(cp_parser_elaborated_type_specifier): Adjust call to
	check_elaborated_type_specifier.
	* typeck2.c (build_functional_cast): Do not perform name lookups.
	
	PR c++/10717
	* decl.c (expand_static_init): Remove unncessary code.
	
	PR c++/10926
	* g++.dg/template/dtor2.C: New test.
	
	PR c++/11684
	* g++.dg/template/operator1.C: New test.
	* g++.dg/parse/operator4.C: New test.
	
	PR c++/11946.C
	* g++.dg/expr/enum1.C: New test.
	* gcc.dg/c99-bool-1.c: Remove bogus warning.
	
	PR c++/11036.C
	* g++.dg/parse/elab2.C: New test.
	* g++.dg/parse/typedef4.C: Change error message.
	* g++.old-deja/g++.robertl/eb133.C: Remove bogus error markers.
	* g++.old-deja/g++.robertl/eb133a.C: Remove bogus error markers.
	* g++.old-deja/g++.robertl/eb133b.C: Remove bogus error markers.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&r1=2.812&r2=2.813
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/c-common.c.diff?cvsroot=gcc&r1=1.448&r2=1.449
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/convert.c.diff?cvsroot=gcc&r1=1.32&r2=1.33
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/config/pa/pa.h.diff?cvsroot=gcc&r1=1.200&r2=1.201
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/ChangeLog.diff?cvsroot=gcc&r1=1.3610&r2=1.3611
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/class.c.diff?cvsroot=gcc&r1=1.563&r2=1.564
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/cp-tree.h.diff?cvsroot=gcc&r1=1.903&r2=1.904
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/decl.c.diff?cvsroot=gcc&r1=1.1113&r2=1.1114
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/decl2.c.diff?cvsroot=gcc&r1=1.661&r2=1.662
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/name-lookup.c.diff?cvsroot=gcc&r1=1.8&r2=1.9
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/parser.c.diff?cvsroot=gcc&r1=1.101&r2=1.102
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/pt.c.diff?cvsroot=gcc&r1=1.760&r2=1.761
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/cp/typeck2.c.diff?cvsroot=gcc&r1=1.147&r2=1.148
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.2981&r2=1.2982
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/expr/enum1.C.diff?cvsroot=gcc&r1=NONE&r2=1.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/parse/elab2.C.diff?cvsroot=gcc&r1=NONE&r2=1.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/parse/operator4.C.diff?cvsroot=gcc&r1=NONE&r2=1.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/parse/typedef4.C.diff?cvsroot=gcc&r1=1.1&r2=1.2
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/template/dtor2.C.diff?cvsroot=gcc&r1=NONE&r2=1.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.dg/template/operator1.C.diff?cvsroot=gcc&r1=NONE&r2=1.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.old-deja/g++.robertl/eb133.C.diff?cvsroot=gcc&r1=1.7&r2=1.8
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.old-deja/g++.robertl/eb133a.C.diff?cvsroot=gcc&r1=1.3&r2=1.4
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/g++.old-deja/g++.robertl/eb133b.C.diff?cvsroot=gcc&r1=1.3&r2=1.4
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gcc.dg/c99-bool-1.c.diff?cvsroot=gcc&r1=1.3&r2=1.4


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

* [Bug c++/11946] [3.4 regression] fun and merriment with enums as function arguments
  2003-08-16 13:54 [Bug c++/11946] New: fun and merriment with enums as function arguments richard dot kreckel at ginac dot de
                   ` (5 preceding siblings ...)
  2003-08-20  7:07 ` cvs-commit at gcc dot gnu dot org
@ 2003-08-20  7:12 ` mmitchel at gcc dot gnu dot org
  2004-06-01 16:10 ` cvs-commit at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2003-08-20  7:12 UTC (permalink / raw)
  To: gcc-bugs

PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

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


mmitchel at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED


------- Additional Comments From mmitchel at gcc dot gnu dot org  2003-08-20 07:12 -------
Fixed in GCC 3.4.


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

* [Bug c++/11946] [3.4 regression] fun and merriment with enums as function arguments
  2003-08-16 13:54 [Bug c++/11946] New: fun and merriment with enums as function arguments richard dot kreckel at ginac dot de
                   ` (6 preceding siblings ...)
  2003-08-20  7:12 ` mmitchel at gcc dot gnu dot org
@ 2004-06-01 16:10 ` cvs-commit at gcc dot gnu dot org
  2004-06-02  5:29 ` cvs-commit at gcc dot gnu dot org
  2004-06-28  8:23 ` cvs-commit at gcc dot gnu dot org
  9 siblings, 0 replies; 11+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2004-06-01 16:10 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From cvs-commit at gcc dot gnu dot org  2004-06-01 16:10 -------
Subject: Bug 11946

CVSROOT:	/cvs/gcc
Module name:	gcc
Branch: 	hammer-3_3-branch
Changes by:	zlomek@gcc.gnu.org	2004-06-01 16:10:10

Modified files:
	gcc            : ChangeLog.hammer convert.c 

Log message:
	PR c/15549
	Backport from mainline:
	
	2003-08-19  Mark Mitchell  <mark@codesourcery.com>
	
	PR c++/11946
	* convert.c (convert_to_integer): Use CONVERT_EXPR (instead of
	NOP_EXPR) when necessary.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.hammer.diff?cvsroot=gcc&only_with_tag=hammer-3_3-branch&r1=1.1.2.405&r2=1.1.2.406
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/convert.c.diff?cvsroot=gcc&only_with_tag=hammer-3_3-branch&r1=1.19.12.5&r2=1.19.12.6



-- 


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


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

* [Bug c++/11946] [3.4 regression] fun and merriment with enums as function arguments
  2003-08-16 13:54 [Bug c++/11946] New: fun and merriment with enums as function arguments richard dot kreckel at ginac dot de
                   ` (7 preceding siblings ...)
  2004-06-01 16:10 ` cvs-commit at gcc dot gnu dot org
@ 2004-06-02  5:29 ` cvs-commit at gcc dot gnu dot org
  2004-06-28  8:23 ` cvs-commit at gcc dot gnu dot org
  9 siblings, 0 replies; 11+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2004-06-02  5:29 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From cvs-commit at gcc dot gnu dot org  2004-06-02 05:29 -------
Subject: Bug 11946

CVSROOT:	/cvs/gcc
Module name:	gcc
Branch: 	hammer-3_3-branch
Changes by:	zlomek@gcc.gnu.org	2004-06-02 05:29:04

Modified files:
	gcc/testsuite  : ChangeLog.hammer 
	gcc/testsuite/gcc.dg: c99-bool-1.c 

Log message:
	PR c/15549
	Backport from mainline
	2003-08-19  Mark Mitchell  <mark@codesourcery.com>
	
	PR c++/11946.C
	* gcc.dg/c99-bool-1.c: Remove bogus warning.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.hammer.diff?cvsroot=gcc&only_with_tag=hammer-3_3-branch&r1=1.1.2.17&r2=1.1.2.18
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gcc.dg/c99-bool-1.c.diff?cvsroot=gcc&only_with_tag=hammer-3_3-branch&r1=1.3&r2=1.3.2.1



-- 


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


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

* [Bug c++/11946] [3.4 regression] fun and merriment with enums as function arguments
  2003-08-16 13:54 [Bug c++/11946] New: fun and merriment with enums as function arguments richard dot kreckel at ginac dot de
                   ` (8 preceding siblings ...)
  2004-06-02  5:29 ` cvs-commit at gcc dot gnu dot org
@ 2004-06-28  8:23 ` cvs-commit at gcc dot gnu dot org
  9 siblings, 0 replies; 11+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2004-06-28  8:23 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From cvs-commit at gcc dot gnu dot org  2004-06-28 08:03 -------
Subject: Bug 11946

CVSROOT:	/cvs/gcc
Module name:	gcc
Branch: 	gcc-3_3-branch
Changes by:	zlomek@gcc.gnu.org	2004-06-28 08:03:48

Modified files:
	gcc            : ChangeLog convert.c 
	gcc/testsuite  : ChangeLog 
	gcc/testsuite/gcc.dg: c99-bool-1.c 

Log message:
	PR c/15549
	Backport from mainline
	2003-08-19  Mark Mitchell  <mark@codesourcery.com>
	
	PR c++/11946
	* convert.c (convert_to_integer): Use CONVERT_EXPR (instead of
	NOP_EXPR) when necessary.
	
	PR c/15549
	Backport from mainline
	2003-08-19  Mark Mitchell  <mark@codesourcery.com>
	
	PR c++/11946.C
	* gcc.dg/c99-bool-1.c: Remove bogus warning.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&only_with_tag=gcc-3_3-branch&r1=1.16114.2.991&r2=1.16114.2.992
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/convert.c.diff?cvsroot=gcc&only_with_tag=gcc-3_3-branch&r1=1.19&r2=1.19.14.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&only_with_tag=gcc-3_3-branch&r1=1.2261.2.379&r2=1.2261.2.380
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gcc.dg/c99-bool-1.c.diff?cvsroot=gcc&only_with_tag=gcc-3_3-branch&r1=1.3&r2=1.3.4.1



-- 


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


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

end of thread, other threads:[~2004-06-28  8:04 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-08-16 13:54 [Bug c++/11946] New: fun and merriment with enums as function arguments richard dot kreckel at ginac dot de
2003-08-16 14:08 ` [Bug c++/11946] " pinskia at gcc dot gnu dot org
2003-08-16 14:31 ` [Bug c++/11946] [3.4 regression] " falk at debian dot org
2003-08-16 21:40 ` richard dot kreckel at ginac dot de
2003-08-17  0:27 ` pinskia at gcc dot gnu dot org
2003-08-19 19:03 ` mmitchel at gcc dot gnu dot org
2003-08-20  7:07 ` cvs-commit at gcc dot gnu dot org
2003-08-20  7:12 ` mmitchel at gcc dot gnu dot org
2004-06-01 16:10 ` cvs-commit at gcc dot gnu dot org
2004-06-02  5:29 ` cvs-commit at gcc dot gnu dot org
2004-06-28  8:23 ` cvs-commit at gcc dot gnu dot 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).