Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
riscv-gcc-1
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
riscv-gcc-1
Commits
51ccaeb9
Commit
51ccaeb9
authored
Apr 26, 2002
by
Alexandre Oliva
Committed by
Alexandre Oliva
Apr 26, 2002
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* gcc.dg/enum1.c: New test.
From-SVN: r52815
parent
b446a5f1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
28 additions
and
1 deletions
+28
-1
gcc/testsuite/ChangeLog
+4
-0
gcc/testsuite/g++.dg/abi/enum1.C
+1
-1
gcc/testsuite/gcc.dg/enum1.c
+23
-0
No files found.
gcc/testsuite/ChangeLog
View file @
51ccaeb9
2002-04-26 Alexandre Oliva <aoliva@redhat.com>
* gcc.dg/enum1.c: New test.
2002-04-26 Mark Mitchell <mark@codesourcery.com>
PR c++/6497
...
...
gcc/testsuite/g++.dg/abi/enum1.C
View file @
51ccaeb9
...
...
@@ -9,7 +9,7 @@ enum foo
foo3
=
0xf0fffffffffffffeULL
};
int
main
(
int
i
)
int
main
()
{
if
(
sizeof
(
enum
foo
)
!=
sizeof
(
unsigned
long
long
))
std
::
abort
();
...
...
gcc/testsuite/gcc.dg/enum1.c
0 → 100644
View file @
51ccaeb9
/* { dg-do run } */
/* { dg-options "-std=gnu89" } */
/* In standard C, enumeration constants always have type int. If they
are not representables are int, they're ill-formed. In GNU C, we
give such ill-formed constructs well-defined meaning. Make sure it
works. */
#include <stdlib.h>
enum
foo
{
foo1
=
0
,
foo2
=
0xffffffffffffffffULL
,
foo3
=
0xf0fffffffffffffeULL
};
int
main
()
{
if
(
sizeof
(
enum
foo
)
!=
sizeof
(
unsigned
long
long
))
abort
();
exit
(
0
);
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment