TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Toward Go 1.3

257 pointsby babawereover 11 years ago

17 comments

CoffeeDregsover 11 years ago
First, I apologize for bringing up something that has been brought up since the birth of Go...<p>I&#x27;m surprised at the lack of progress in generics for Go. But more than <i>progress</i>, I&#x27;m surprised at the lack of a <i>story</i> about generics in Go. Yes, the FAQ waves its hands at complexity, but the lack of discussion and&#x2F;or proposals puzzle me. The wiki page about it (<a href="https://code.google.com/p/go-wiki/wiki/GoVsGenerics" rel="nofollow">https:&#x2F;&#x2F;code.google.com&#x2F;p&#x2F;go-wiki&#x2F;wiki&#x2F;GoVsGenerics</a>) is tiny and feeds from this discussion (<a href="http://groups.google.com/group/golang-nuts/browse_thread/thread/3d825ac84e742598" rel="nofollow">http:&#x2F;&#x2F;groups.google.com&#x2F;group&#x2F;golang-nuts&#x2F;browse_thread&#x2F;thr...</a>). I would be much more interested in Go were there some evidence for the intent to implement generics. A related concern is that adding generics will have a significant affect on libraries and existing code, so adding generics will become harder the longer Go waits.<p>I would be very happy to have the Go team say: we&#x27;re going to focus on adding generics to Go in 2.0 and will be considering how to get there sooner than later; that said, we don&#x27;t know when 2.0 will be released, but building in generics will drive 2.0.<p>Note: I understand the workarounds, but they&#x27;re either hacky or have terrible performance. And I also understand that users of Go say that they don&#x27;t miss generics, but I&#x27;m just not comfortable believing that.
评论 #7218862 未加载
评论 #7219356 未加载
评论 #7218839 未加载
评论 #7220979 未加载
评论 #7221202 未加载
评论 #7218815 未加载
评论 #7220639 未加载
评论 #7219417 未加载
voidlogicover 11 years ago
Using sync.Pool for my personal projects has made them so much faster (&#x2F; use less heap) and let me retire my custom pools. So much awesome there.<p>This presentation also doesn&#x27;t mention the concurrent GC sweep work: <a href="https://codereview.appspot.com/46430043/" rel="nofollow">https:&#x2F;&#x2F;codereview.appspot.com&#x2F;46430043&#x2F;</a>
评论 #7218882 未加载
评论 #7221164 未加载
gtaylorover 11 years ago
The combination of NaCl support and Objective C linking support make me wonder whether we will see Go creep towards being an officially &quot;blessed&quot; and privileged language (like Java and C+NDK) for Android development in the future.<p>I would assume that the NaCl support means that we&#x27;ll be able to write things for Chromebooks relatively easily?
评论 #7221158 未加载
评论 #7218909 未加载
NateDadover 11 years ago
The lack of generics in Go is hugely over-hyped as a problem.<p>There are generic lists (slices &amp; arrays), there are generic maps (dictionaries). You can build a hell of a lot on top of that.<p>To generalize logic, Go&#x27;s interfaces are amazing.<p>There are some huge projects out there using Go, and not hurt by the lack of generics. Perhaps you&#x27;ve heard of Docker?<p>I work on Juju[1], a Go project that is over 200,000 lines of code. There&#x27;s only a handful of places where generics would have made things a little easier, and it&#x27;s never been &quot;OMG this is so awful because we don&#x27;t have generics&quot;.<p>And this is coming from a guy who spent his first 14 years programming in C++ and C#, so it&#x27;s not like I&#x27;m not used to generics. You just write code in a different way. Sometimes you can&#x27;t get around it when you need a containery class, so you use interface{} and cast the result, but that&#x27;s the exception rather than the rule.<p>[1] <a href="http://juju.ubuntu.com" rel="nofollow">http:&#x2F;&#x2F;juju.ubuntu.com</a>
leocover 11 years ago
&quot;Go 1.3 targets that command-line tool for 32-bit and 64-bit x86 architectures.<p>(NaCl supports 32-bit ARM, but we have no plans to support it.)&quot;<p><i>epic facepalm</i>
评论 #7218800 未加载
评论 #7218660 未加载
评论 #7222637 未加载
steeveover 11 years ago
Noting that I&#x27;m successfully running Go 1.2 binaries with CGO on android&#x2F;arm, cross-compiled from darwin&#x2F;amd64 (my macbook).<p>You can check out the Makefiles in libtorrent-go[1] and torrent2http[2]<p>[1] <a href="https://github.com/steeve/libtorrent-go" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;steeve&#x2F;libtorrent-go</a><p>[2] <a href="https://github.com/steeve/torrent2http" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;steeve&#x2F;torrent2http</a>
sdegutisover 11 years ago
&gt; <i>Compiler overhaul: the plan. Not a rewrite. Translate the C compilers to Go. Write and use an automatic translator to do this. Start the process with Go 1.3 and continue in future releases.</i><p>Aww. Transliterated C code does not sound like it will take full advantage of Go idioms. Plus, an automatic translator? Unless it is extremely disciplined C code, that sounds harder than just translating it by hand.
评论 #7219050 未加载
评论 #7219083 未加载
评论 #7218997 未加载
评论 #7218838 未加载
评论 #7218846 未加载
评论 #7221006 未加载
sdegutisover 11 years ago
&gt; <i>Support for linking against Objective C code</i><p>This is the most exciting part for me! Although I wish they didn&#x27;t skim so much on the technical detail here.
评论 #7218812 未加载
评论 #7218765 未加载
评论 #7222088 未加载
kenshiro_oover 11 years ago
Forgive my ignorance but what does 100% Precise GC means?
评论 #7218797 未加载
评论 #7218804 未加载
评论 #7218897 未加载
评论 #7218832 未加载
评论 #7218772 未加载
评论 #7218787 未加载
pjmlpover 11 years ago
Instead of doing my usual comments about Go&#x27;s design, I would rather congratulate the team in what they have achieved so far.
japagetover 11 years ago
I had to use the Page Up and Page Down keys to navigate this; apparently either the mouse is not supported, or I couldn&#x27;t figure out how to navigate this site with the mouse.
评论 #7218704 未加载
评论 #7218657 未加载
Zenstover 11 years ago
From way in the slides I saw this and got excited:<p>&quot;darwin&#x2F;arm, android&#x2F;arm: a contributor is working on these, some way to go.&quot;
leothekimover 11 years ago
One of the bullet points:<p>- &quot;Clean up and document the code, add unit tests. (Target Go 1.4)&quot;<p>Oh sure, add features now and add the unit tests later. :-D #joking
namelezzover 11 years ago
Wow March 1, 2014. What an exciting month with Go 1.3 and Java 8.
评论 #7229545 未加载
评论 #7219283 未加载
clhodappover 11 years ago
Either these slides mischaracterize what liblink does or it has the wrong name. The fact that it does things that the linker used to do doesn&#x27;t mean it is doing linking.
评论 #7221021 未加载
justinsbover 11 years ago
So &quot;liblink&quot; means that the compilers now generate native instructions, rather than pseudo-instructions. Seems like that would make it much tougher to implement generic methods. Anyone know if that&#x27;s true?
评论 #7219061 未加载
syaramakover 11 years ago
Slightly off topic, but is there a mobile friendly version of this site?
评论 #7218668 未加载
评论 #7218715 未加载
评论 #7220213 未加载
评论 #7220037 未加载
评论 #7218852 未加载