4 ms·
I you've written advanced-enough go, you probably have a bunch of file that start with some C code before the Go code starts. Go simply can't interface everyth
by zobzu 11y ago
I you've written advanced-enough go, you probably have a bunch of file that start with some C code before the Go code starts.
Go simply can't interface everything the way C does. Go doesn't give you the same level of flexibility either.
tldr: Go's great, but it's just not as powerful as C (unlike Rust or some others, which can do anything C does).
- _ak 11y agoWhat specifically are you talking about? Go can do syscalls perfectly fine, you can mess in your memory perfectly fine (even if you have to resort to the unsafe package), so what exactly is it where you think Go lacks flexibility compared to C? Because so far, your posting sounds rather hand-wavy.
- wishing_for_ffi 11y agoOne problem is that it's very hard to call go libraries from other languages (it requires a runtime). C libraries can be called from almost any language. There are many go libraries I would love to use, but can't because of this. I expect many others are in a similar boat.
- zobzu 11y agoFor ex try to read the data from a signal. Another example is to start a namespace before all threads start. I can go on for a while :)