History

enums and ints are compatible

But like GCC do warn about changes in signedness. The latter leads to some changes in gen_assign_cast to not also warn about unsigned* = int* (where GCC warns, but only with extra warnings).

Michael Matz committed 10 years ago

Commit 34fc6431 parent b1a906b4 files · +35 −14Browse files

Showing the changes to tests (1 of 4 files). Show all

Unified · Split

tests/tcctest.c+1−1
@@ -591,7 +591,7 @@ void enum_test() · 590 unmodified lines
591591 {
592592 enum test b1;
593593 /* The following should give no warning */
594− int *p = &b1;
594+ unsigned *p = &b1;
595595 printf("enum:\n%d %d %d %d %d %d\n",
596596 E0, E1, E2, E3, E4, E5);
597597 b1 = 1;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t