golang/go
View on GitHub ↗ ★ 139,735 Go
The Go programming language
1,947 mentions on Hacker News by 1,181 people: 291 stories, 1,656 comments · first 2014-12-08 · latest 2026-10-22
20082026
-
https://tpaschalis.me/goroutines-size/ https://github.com/golang/go/blob/master/src/runtime/stack.g...
comment by liveoneggs · 2024-11-29 · in How much memory do you need in 2024 to run 1M concurrent tasks? -
…falls over if you breathe on it ( https://pkolaczk.github.io/overhead-of-optional/ ). According to https://github.com/golang/go/discussions/70257#discussioncom... > the weak generational hypothesis does not hold up well with respect to…
comment by masklinn · 2024-11-24 · in Mark–Scavenge: Waiting for Trash to Take Itself Out -
…not to benefit when a significant fraction of the newborn objects don't even reach the youngen. See https://github.com/golang/go/discussions/70257#discussioncom... from the current discussion of adding opt-in ad-hoc support for memory…
comment by masklinn · 2024-11-24 · in Mark–Scavenge: Waiting for Trash to Take Itself Out -
To be fair to those projects, the type was introduced only three years ago: https://github.com/golang/go/pull/49359/files Before that, doing a string compare was basically the only way to detect that specific error. That was definitely an…
comment by gwd · 2024-11-21 · in Hyrum’s Law in Golang -
But it looks like that until 3 years ago, this string comparison was the only way to do it. https://github.com/golang/go/pull/49359/files
comment by sssddfffdssasdf · 2024-11-21 · in Hyrum’s Law in Golang -
There is actually a proposal to make type constraints act as sum types: https://github.com/golang/go/issues/57644 But I doubt sum types will be supported perfectly in Go. The current poor-men's sum type mechanism (type-switch syntax) might…
comment by tapirl · 2024-11-17 · in Constraints in Go -
…more limitations in current Go custom generics, much of them could be removed when this proposal ( https://github.com/golang/go/issues/70128 ) is done. I recommend people to read Go Generics 101 ( https://go101.org/generics/101.html ,…
comment by tapirl · 2024-11-17 · in Constraints in Go -
…for sure. Go core team have admitted this but refused to fix it for Go 1.22.n toolchains: https://github.com/golang/go/issues/66092 And, even for the Go code with go.mod involved, there are some behavior change cases which will be not…
comment by tapirl · 2024-11-12 · in Go Turns 15 -
Tried to contribute to a Go project a few months ago and got bitten by https://github.com/golang/go/issues/67296 due to questionable doc quality. I was pretty disappointed to find that natural sort isn't builtin since Go was the Unicode…
comment by a-french-anon · 2024-11-12 · in Go Turns 15 -
…to the 3-clause "for;;" loops: * https://go101.org/blog/2024-03-01-for-loop-semantic-changes-... * https://github.com/golang/go/issues/66156 * https://x.com/zigo_101/status/1856173025839960333 * https://x.com/zigo_101/status/185491826252362…
comment by tapirl · 2024-11-12 · in Go Turns 15 -
…only trivial ones without local captures?), maps (probably no)...? I think the relevant code is https://github.com/golang/go/blob/master/src/runtime/mgc.go and adjacent files. I see some annotations like //go:systemstack, //go:nosplit,…
comment by ben0x539 · 2024-11-08 · in Rust for tokenising and parsing -
…point there was even a bit of drama[1] around it being marked as deprecated instead of frozen. [0]: https://github.com/golang/go/issues/61917 [1]: https://github.com/golang/go/issues/60797
comment by boomskats · 2024-11-07 · in Linux Syscall Support -
…the 'tar' package in go by default returns unsanitized paths, and has led to a bunch of CVEs: https://github.com/golang/go/issues/55356 The go stdlib can't change the tar package to make it secure by default because it would be a breaking…
comment by TheDong · 2024-11-05 · in Writing secure Go code -
…worse than Java in this regard. I'll just give you a random example from my five seconds of search: https://github.com/golang/go/issues/37484
comment by kccqzy · 2024-11-05 · in Writing secure Go code -
You should read that article carefully. Some Go core team members don't agree with you: https://github.com/golang/go/issues/66156
comment by tapirl · 2024-11-05 · in Writing secure Go code -
…mutability, and would still be a problem even in the presence of full memory safety, for instance: https://github.com/golang/go/issues/37669 https://github.com/golang/go/issues/48340 These types of race conditions cannot happen in Rust.…
comment by unscaled · 2024-11-05 · in Writing secure Go code -
There might be some bugs in .2: https://github.com/golang/go/issues/70035
comment by tapirl · 2024-11-04 · in Writing secure Go code -
It indeed is. Please read https://go101.org/blog/2024-03-01-for-loop-semantic-changes-... and https://github.com/golang/go/issues/66156
comment by tapirl · 2024-11-04 · in Writing secure Go code -
…are no tools to detect the new footguns created by the new semantics of 3-clause "for;;" loops: https://github.com/golang/go/issues/66156 > The second step is to keep the Go versions in our projects current. Even though we don’t use the…
comment by tapirl · 2024-11-04 · in Writing secure Go code -
…the European winter (i.e. the opposite of the other European timezones). (More details here: https://github.com/golang/go/issues/56743#issuecomment-13157... ) Edit: To be clear: the quote is referring to a negative DST start, rather than a…
comment by LysPJ · 2024-10-30 · in Australia/Lord_Howe is the weirdest timezone -
…to address this issue, but fixing it has generally been rejected by the language maintainers, e.g. https://github.com/golang/go/issues/42713 , with the argument that fixing it directly just provides an illusion of security.
comment by kbolino · 2024-10-28 · in Jia Tanning Go Code -
…implementations because it wasn't technically correct. https://github.com/nodejs/node/issues/14644 https://github.com/golang/go/issues/21326 And someone even ended up making a website http://save418.com/
comment by 0x00cl · 2024-10-28 · in 418 I’m a teapot -
You nerd sniped me. The guts of how http2 deals with this in golang is in transport.go : https://github.com/golang/go/blob/master/src/net/http/transp... If I’m reading the code right round trips (HTTP requests) go through queueForIdleConn…
comment by __turbobrew__ · 2024-10-27 · in Understanding Round Robin DNS -
(Rejected) proposal to add something like this to the standard library gives some context: https://github.com/golang/go/issues/53171
comment by dpifke · 2024-10-18 · in Show HN: Go Plan9 Memo -
If you want to see some Plan9 in the std library check out the math package! https://github.com/golang/go/tree/master/src/math
comment by pehringer · 2024-10-18 · in Show HN: Go Plan9 Memo -
…in some cases. But I do wonder, why the std lib doesn't offer this ? EDIT: I found the anwser: https://github.com/golang/go/issues/53171 Here is a good explanation provided by Ian Lance Taylor: > This proposal is focused on code generation…
comment by nzach · 2024-10-18 · in Show HN: Go Plan9 Memo -
…2000, but that part's optional. - I would say Go is completely irrelevant, since AFAICT as of https://github.com/golang/go/issues/57003 it only supports... Windows 8+? It's actually really hard to find an official answer to what platform…
comment by yjftsjthsd-h · 2024-10-11 · in Running WolfSSL and Curl on Windows 2000 -
…at build time, or on (b) by making generic methods "homegenous" (aka boxed) and thus slow (see https://github.com/golang/go/issues/49085#issuecomment-23163... for an elaboration of this approach); or, they involve dynamic code generation.
comment by adonovan · 2024-10-11 · in Fun with Go Iterators -
https://github.com/golang/go/issues/49085
comment by tapirl · 2024-10-10 · in Fun with Go Iterators -
Another thing I want but is completely missing from golang.org/x/crypto/ssh is compression support: https://github.com/golang/go/issues/31369
comment by oefrha · 2024-10-09 · in Show HN: I made an SSH tunnel manager to learn Go -
I believe these are the issues: https://github.com/golang/go/issues/52690 https://github.com/ziglang/zig/issues/14989
comment by dwattttt · 2024-10-02 · in The Fastest Mutexes -
…(read: fixed / un-broken) some of this setup would be a lot easier, but not holding my breath. [1]: https://github.com/golang/go/issues/48429 [2]: https://go.googlesource.com/proposal/+/54d6775ff71ccbc00c276...
comment by pentaphobe · 2024-10-01 · in Using a separate Go module for your tools.go -
https://github.com/golang/go/issues/54380 I didn't know about that. I agree it qualifies as a "weird issue".
comment by arp242 · 2024-09-30 · in Some Go web dev notes -
…alignment rules as C to make cgo work. There they also solved it by adding dedicated atomic types. https://github.com/golang/go/discussions/47141
comment by EdSchouten · 2024-09-29 · in The perils of transition to 64-bit time_t -
We agreed to make the threadsafeness more explicit in the documentation of the 'unique' package: https://github.com/golang/go/issues/69637
comment by val_deleplace · 2024-09-27 · in Interning in Go -
…It's always nice to see harder concepts implemented with simplicity and readability in mind. [0] https://github.com/golang/go/blob/master/src/cmd/compile/int...
comment by fuhsnn · 2024-09-24 · in Register Allocation in the Go Compiler -
Be aware that there is a bug in the current implementation (1.23.0 and 1.23.1) https://github.com/golang/go/issues/69370
comment by tapirl · 2024-09-19 · in Interning in Go -
…I wonder how much difference this little fix mentioned in the article for go1.23.2 will make? https://github.com/golang/go/issues/69370 The article also mentions strings.Clone which has been around for a while. Using that is very easy and…
comment by nickcw · 2024-09-19 · in Interning in Go -
…) Related tickets, "runtime: add AddCleanup and deprecate SetFinalizer" - https://github.com/golang/go/issues/67535 "weak: new package providing weak pointers" - https://github.com/golang/go/issues/67552 One day Go will eventually h
comment by pjmlp · 2024-09-19 · in Interning in Go -
…idiomatic in go, if you follow the stdlib. Like, are you doing anything with TLS? String matching: https://github.com/golang/go/issues/35234 Using the stdlib ssh stuff? String matching: https://github.com/golang/go/issues/45207 /…
comment by TheDong · 2024-09-11 · in Don't defer Close() on writable files (2017) -
…a surprising amount of languages/libraries/frameworks/servers where the support is missing (e.g. go https://github.com/golang/go/issues/49918 ). On the client side, both Chrome ( https://chromestatus.com/feature/6251293127475200 ) and…
comment by realharo · 2024-09-06 · in Intent to unship: HTTP/2 Push -
…the go tooling doesn't have a more native way to do something like this already. Upstream issue: https://github.com/golang/go/issues/50745 Like, go already has test caching (so "only test stuff that changed" shouldn't be necessary, that…
comment by TheDong · 2024-08-26 · in Show HN: Monogo – Evolve your go workspace to a real monorepo -
You can learn from the Go codebase to get a feel of why this is useful: https://github.com/golang/go/blob/master/src/cmd/go/internal... https://github.com/golang/go/blob/master/src/io/fs/fs.go#L26... https://github.com/golang/go/blob/master…
comment by mseepgood · 2024-08-21 · in Duck typing (horror) in Go -
…in fact. Go core team has admitted that Go toolchain 1.22.n versions break backward compatibility: https://github.com/golang/go/issues/66092 There is another breakage case: https://github.com/golang/go/issues/66070 and the team leader…
comment by tapirl · 2024-08-21 · in Go automatically downloads a newer toolchain if needed -
…follow. Why would getting sum types in go be impossible? There is already a proposal for this: https://github.com/golang/go/issues/57644 The generic type params already supports a sum type like interface, it’s almost there. So, if you…
comment by MarkMarine · 2024-08-18 · in An unordered list of things I miss in Go -
…receiver gets the wakeup. That's why I brought it up: no it isn't. It's ordered. Intentionally. https://github.com/golang/go/issues/11506 It's pretty easy to prove to yourself too, it only takes a couple dozen lines to write a test. I'm…
comment by Groxx · 2024-08-18 · in An unordered list of things I miss in Go -
> Is Go adding a random seed to each hash map? Yes: https://github.com/golang/go/blob/27093581b2828a2752a6d2711d...
comment by jhgg · 2024-08-17 · in An unordered list of things I miss in Go -
…Maybe a = Just a | Nothing`) rather than current {sql,null}.Null* mess or whatever was proposed in https://github.com/golang/go/issues/48702 . But I doubt if that'll ever happen.
comment by drdaeman · 2024-08-17 · in An unordered list of things I miss in Go -
…The discussion was heavily moderated and redacted, it was even more "lively" at the time.) [1] https://github.com/golang/go/discussions/58409
comment by traceroute66 · 2024-08-13 · in Go 1.23 Released -
…on the relevant Github topic[1], it was changed to opt-in. :D Opt-in is the correct stance. [1] https://github.com/golang/go/discussions/58409
comment by traceroute66 · 2024-08-13 · in Go 1.23 Released