projects
/
cparser
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8e0cc9a
)
sizeof(void) is 1
author
Matthias Braun
<matze@braunis.de>
Tue, 25 Oct 2011 10:55:44 +0000
(12:55 +0200)
committer
Matthias Braun
<matze@braunis.de>
Thu, 27 Oct 2011 10:20:37 +0000
(12:20 +0200)
This only matters when GNU mode is enabled, but then you can perform
pointer arithmetic with void in which case its size should also be 1
type.c
patch
|
blob
|
history
diff --git
a/type.c
b/type.c
index
a0ee6e3
..
8ba008d
100644
(file)
--- a/
type.c
+++ b/
type.c
@@
-83,8
+83,8
@@
type_t *allocate_type_zero(type_kind_t kind)
*/
atomic_type_properties_t atomic_type_properties[ATOMIC_TYPE_LAST+1] = {
[ATOMIC_TYPE_VOID] = {
- .size =
0
,
- .alignment =
0
,
+ .size =
1
,
+ .alignment =
1
,
.flags = ATOMIC_TYPE_FLAG_NONE,
.rank = 0,
},