4 ms·
Curiously, I get why Go doesnt include the source code in its binaries — presumably a hangover from the long standing tradition of source for me but not for the
by gorgoiler 2y ago
Curiously, I get why Go doesnt include the source code in its binaries — presumably a hangover from the long standing tradition of source for me but not for thee, as well as sever constraints on resources meaning source-included would be a frivolity — but are there compiled languages where it is an option to include the source?
The only one I can think of is TypeScript where it builds source maps to help debug the underlying JavaScript without having to see it.
- usrusr 2y agoHad the same thought recently. But it would be easy enough to make a "go script" frontend that checks for a compiled version, checks the source against a hash stored with that compiled version and shortcuts to the binary if everything matches, (re)creating it if not.
- forrestthewoods 2y agoMy opinion is that source code should be packaged up with debug symbols. I'm also a fan of breaking out debug symbols from the exe although that's a separate topic.