4 ms·
You're not going to write microcontroller firmware in Go, but several people are doing just that in Rust, and it actually works quite well. Philosophy aside, i
by ohazi 6y ago
You're not going to write microcontroller firmware in Go, but several people are doing just that in Rust, and it actually works quite well.
Philosophy aside, in actual use Go is a better Java, not a better C.
If your C program could have been a Java program, then go ahead and use Go. But lots of C and C++ programmers who consider Rust and decline to consider Go do so because the trade-offs that Go makes (garbage collection, error handling ergonomics, generics, etc.) really aren't that appealing. Not everybody is writing web servers for big-iron Google servers.
- dathinab 6y agoStill go had been designed with some philosophical overlap with C, just with a GC. And then massive concurrency was added. Anyway go is mostly good for cases where C or a very C like C++ where used but C want the best fit, like certain server applications. Ironically it's design makes it also pretty bad for many other server applications.
- valbaca 6y ago"Ironically it's design makes it also pretty bad for many other server applications." Can you elaborate? genuinely curious
- lostmsu 6y ago> Go is a better Java Maybe off topic, but I highly doubt Go is better than Java. Have not seen anyone convert to it from Java yet. Most come from Python.
- theredbox 6y agoI tend to think about Go as a compiled bash :-)
- valbaca 6y agoJava dev here (10yrs). I would like to consider Go a better Java. I'm still collecting data and it'll be hard to move away from Java's established position.
- hbogert 6y agoI used java starting in high-school and got it extensively in Uni. I've been using Golang for the last half year and it feels like I'm reliving the dark ages in which java has lingered so long. Heavily patterned, but even dumber than java 5 was. Omission of language functionality and/or constructs is always attributed to "this was intended, the language doesn't need it", however I DO want generics. Go has remedied C's memory unsafety, yet meanwhile 1) it made no strides in a multi-threaded model when it comes to safety. (can't stand Mutexes anymore) 2) shooting yourself in the foot with nil's is still rampant. 3) A project codebase file hierarchy is overly non-opiniated but everybody has "the one and true" project hierarchy. Yet all I hear is praise, I just don't get it. The reinvention of completely static binaries is cool sometimes, and not having to deal with a bloated runtime like the JVM is indeed a blessing, other than that, it feels like we're praising the (relatively) new kid on the block because he comes from the big city (Google)
- SAI_Peregrinus 6y agoI work for a company that switched from Java to Go last year. There's still some legacy Java code but it's steadily being replaced. Though I'm not on that side of the business (backend) so I rarely interact with either language as an embedded dev.