<html>
<head>
<meta content="text/html; charset=iso-8859-2"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<br>
<blockquote cite="mid:54A174CD.1070701@gmail.com" type="cite">Preco?
TBar mas explicitne zarovnany na 1. Co nemas explicitne zarovnane
je union, ten bude zarovnavany na 4B. Jeho velkost je dana vacsou
polozkou, teda "uint16_t c[3]". 16-bit polozka sama osebe nema byt
preco natahovana na 4B, teda velkost c[3] je 6B. Ale union ako
celok MUSI byt doplneny paddingom na 4B zarovnanie, tu na 8B. No a
v TBar to spolu s "uint16_t a" vyjde na 10B.
<br>
</blockquote>
<br>
Predpokladam, ze v tomto kvize ide o to, ze v dokumentacii sa pise:
"Specifying this attribute for <code>struct</code> and <code>union</code>
types is
equivalent to specifying the <code>packed</code> attribute on each
of the
structure or union members."... a ono to neplati pre vnorene
struct/union, kazdy struct/union musi mat svoje atributy - viz
<a class="moz-txt-link-freetext" href="https://gcc.gnu.org/onlinedocs/gcc/Type-Attributes.html">https://gcc.gnu.org/onlinedocs/gcc/Type-Attributes.html</a><br>
<br>
A v dalsom kole sa bude kydat na open source, jeho autorov a
dokumentaciu...<br>
<br>
-m-<br>
</body>
</html>