4 ms·
Isn't that just Go? They always had their own standard library (which they would never update to use newer syscalls).
by stefan_ 6y ago
Isn't that just Go? They always had their own standard library (which they would never update to use newer syscalls).
- Ericson2314 6y agoParts of Go's runtime are written in C, so the end-to-end being single-language is emphatically not like Go. relibc is a genuine libc implementation. However, I do believe Rust on Redox might indeed not factor through relibc's C interface for everything, taking advantage of Rust being on both sides. That is like Go.
- jchw 6y ago> Parts of Go's runtime are written in C, ? You can build the Go toolchain (and many other Go apps, so as long as they do not hard depend on C) with CGo disabled. I do not believe this is true. Source, although it is self-evident for Go developers who dabble in cross-compilation. https://golang.org/doc/faq#What_compiler_technology_is_used_to_build_the_compilers https://golang.org/doc/faq#What_compiler_technology_is_used_... (I do think there are optional C dependencies, but that shouldn’t be important; you can go end-to-end without C with exceedingly few compromises.)
- Ericson2314 6y agohttps://stackoverflow.com/questions/34756262/how-is-it-possible-for-the-go-runtime-to-be-written-in-go https://stackoverflow.com/questions/34756262/how-is-it-possi... Wow, OK. Go's GC is in Go. I'm very jealous; I've wanted this for Haskell for a long time.
- pjmlp 6y agoAnd here is the source code for the Oberon's one, in Oberon. https://people.inf.ethz.ch/wirth/ProjectOberon/Sources/Kernel.Mod.txt https://people.inf.ethz.ch/wirth/ProjectOberon/Sources/Kerne... Or the JikeRVM implementation in Java. https://github.com/JikesRVM/JikesRVM/tree/52582fa1c519d48fe0a80b57bd5883548e90860f/MMTk https://github.com/JikesRVM/JikesRVM/tree/52582fa1c519d48fe0...
- thayne 6y agoldd tells me go depends on libc and libpthread (at least on linux), so it still needs c code at runtime.
- jchw 6y agoAll you have to do is build the toolchain with CGO_ENABLED=0. The optional CGo bits are not needed for anything that the compiler cares about I don’t think; IIRC with CGo enabled it will use the system’s DNS resolver on Linux for example, instead of reading resolv.conf and talking to DNS servers directly.