NOTE: This series only covers Zig 0.11.0! Help me create more content like this!
www.paypal.com...
Zig doesn't have interfaces as part of the language itself, but it does provide the low-level building blocks that allow you to create your own type of interface mechanism. In this episode, we see the two most common way of building your own interfaces in Zig: tagged unions and pointer casting.
The code: codeberg.org/d...
Relevant Links:
- www.openmymind...
- zig.news/krist...
- • Runtime polymorphism: ...
Негізгі бет Zig in Depth: Interfaces
Пікірлер: 27