Compound data type: Difference between revisions
→{{header|Vlang}}: Rename "Vlang" in "V (Vlang)"
(→Class instance: minor simplifications, + type constraint) |
(→{{header|Vlang}}: Rename "Vlang" in "V (Vlang)") |
||
Line 2,710:
End Structure</syntaxhighlight>
=={{header|V (Vlang)}}==
Vlang also supports embedding structs into other structs and assigning methods to structs.
<syntaxhighlight lang="v (vlang)">struct Point {
x int
y int
|