4 ms·
There are other ways to address this issue. You can do what Swift does and call into libclang so that you can pull out the structure definitions, for instance.
by pcwalton 10y ago
There are other ways to address this issue. You can do what Swift does and call into libclang so that you can pull out the structure definitions, for instance.
Furthermore, if your frontend doesn't know about structure layout then you forgo some important systems language features. For example, you can't implement sizeof as a compile time constant.
- Araq 10y ago> There are other ways to address this issue. You can do what Swift does and call into libclang so that you can pull out the structure definitions, for instance. Sure and you only need to call libclang for each different platform. Or is it on every platform? ;-)