1. 1

    Really happy to see a focus on accessibility here. I’ve been doing some accessibility testing across platforms and GTK seemed to be especially lacking. Hopefully this improves.

    1. 26

      I’m pretty surprised by the amount of hate for Go in the comments here. I definitely agree with the author. For me the simplicity of Go has been an absolute breath of fresh air. It really feels like a better C.

      C doesn’t have generics and yet you don’t hear people complain about that. Right now if you want a statically typed, garbage collected language, your only real options are Java (JVM languages) or Go. The cross platform support for C# is still pretty poor, and many of the smaller languages just don’t have the library support.

      I just don’t see the lack of generics as an issue right now, but I hope that the new generics proposals for Go2 get it right.

      1. 28

        Generics weren’t really a thing until 1973 with ML. C was released in 1972, so it gets some slack. Generics were pretty well understood for decades before Go came out which is why people go off about it.

        1. 13

          The problem is that many people aren’t advocating Go as a better C, but as better, period. And many other people are denouncing Go as a bad language, period. The result is polarization which shows up as ‘hate’ (I would prefer to call it ‘unmoderated negativity’, because I don’t know (and cannot really imagine) if people actually feel hate).

          It would be much nicer if everyone applied the principles of humanity and charity

          1. 6

            C has the preprocessor, which lets you build things like generic redblack trees. Of course, in go, you have go generate. So I think it comes out about even, but because the two features aren’t identical people don’t really consider them.

            For that matter, c++ templates frequently boil down to tons of duplicated code generation, which then the linker has to sift through. Go’s solution requires a touch more work, but eliminates a lot of eventual waste.

            1. 5

              C Preprocessir and go generate might be about equal in what they can do, but there’s no question that C Preprocessir has a lower barrier to entry for the basic things.

              1. 2

                Preprocessor a separate language and tool from C, though. It’s not like having the feature built into the language with the compiler being able to understand the context as it applies the feature.

              2. 5

                I’m not sure that I agree about the C# bit. Why do you say that the cross platform support is poor?

                1. 10

                  Seriously, it feels bizarre using Mono for about a decade, yet people act like .NET only appeared outside of Windows when .NET Core was busy being born a few years ago.

                2. 7

                  It really feels like a better C.

                  So… if you ignore the past 30 years of academic research, it’s a good language? How exactly is that impressive?

                  C doesn’t have generics and yet you don’t hear people complain about that.

                  I’ve never used generics, and I’ve never missed ’em.

                  1. 4

                    I more or less begrudgingly agree. Every now and then I find myself wishing for generics or operator overloading in Go (not as often as I would have guessed)… then I remember how refreshing it is to be able to read some unfamiliar Go code and know that I don’t have to wonder what an innocuous looking “+” might be doing.

                    1. 9

                      You can have generics without operator overloading, though. See also: Java 5.

                    2. 0
                      1. 12

                        Not in the sense that anyone cares about. It doesn’t allow for user-defined generic code – the library author has to write the specialized implementations ahead of time, and exhaustively enumerate what types their macro is generic over. This feature exists almost exclusively for the benefit of tgmath.h.

                        C would have been better off without this poorly thought out solution.

                    1. 2

                      I would also be interested.

                      1. 8

                        AMP is bad for the open web. Google is touting AMP as a way to reduce page load times, but it’s actually about pushing their proprietary HTML standard.

                        Google could easily reduce page load times if they penalized slow loading sites, but they won’t, because doing so doesns’t help push their agenda.

                        Until the AMP specification allows loading JavaScript from somewhere other than https://cdn.ampproject.org AMP cannot be considered an open standard.

                        1. 1

                          “…it’s actually about pushing their proprietary HTML standard.”

                          I don’t think that is quite it. AMP is Google’s equivalent of the Facebook walled garden, not socially, but attempting to constrain you to their walled off part of the internet. The longer they can keep you on a google server the better tracking they can do. See also gmail, YouTube, android, chrome. Don’t get me wrong, it’s still horrible, but I think tracking is the exact reason they created/bought all these products.

                        1. 5

                          :) Very entertaining read. I’ve been picking up some smaller components in GO lately. I’ve also rewritten a component I originally built in Python in GO. Which gives a nice but anecdotal comparison:

                          Python: 11 days of development, performance, 160ms for ranking 3600 activities GO: 3 days of development, performance, 6ms for ranking 3600 activities

                          The project is quite simple. It reads a ranking formula and turns it into a function which runs scoring on a large list of activities. Here’s an example ranking config:

                          "defaults": {
                              "popularity": 1


                          So you basically you need to parse the score expression, translate it to AST, configure the defaults in the context, setup partials for the specified functions, add a bunch of builtin functions and create a huge set of test cases to make sure you’ve covered every possible way in which people can break it :)

                          With Python most of the time was spent on benchmarking and performance optimization. The GO code started out at 15ms and with some super simple optimization came down to 6. (GO also had the unfair advantage of a better expression parsing library being available.)

                          I used to believe that GO gives you better performance at the cost of developer productivity. For certain projects it definitely seems to beat Python at both productivity and performance though.

                          1. 6

                            Is it possible that some of the drop in development time was due to being familiar with the application because you had already written it once before?

                            1. 3

                              You beat me to it. There’s been a lot of rewrite stories debunked because the developers just got better at solving the problem since the first try. That included one with formal methods at IBM that got me where nobody mention it was a second implementation.

                              The proper comparison is doing them both the same way with same primitives. That is closer to apples to apples.

                              1. 2

                                Yeay, it’s comparing apples and oranges :) On the other hand this was my first non-hello world GO project. I’ve been working with Python for 10 years now. GO is super easy to switch to if you’ve been working with Python.

                                Most of the time with the Python version was spent on performance optimization. I think GO hits a sweet spot. The language is easy to use and quite productive. Maybe not as easy as Ruby or Python, but pretty close. GO is also not as fast as C++ or Java (it depends a bit on the code you’re running, but in general it’s a little bit slower).

                                Basically you get close to C++ level performance at close to Python level ease of use. Now for most use cases i’d still recommend Python. (usually it’s just glue between heavily optimized databases and the overhead of python doesnt matter). But for use cases where the language performance matters, GO really hits a sweet spot.

                                1. 3

                                  Nit: it’s Go, not GO.

                                  1. 3

                                    People are never going to get this right. It’s Go: not Golang, GO, Google’s Go, etc.

                                    1. 2

                                      haha, that’s probably the hardest aspect of learning Go :)

                              1. 8

                                Sorry this happened. As a US resident, I didn’t realize how crazy it can be entering or leaving the United States until I did so for the first time. The US was by far the hardest country to get into for me (even though I’m a citizen). It’s a shame that interactions with customs is such a mixed bag, and I worry that it is actually going to get worse for the time being.

                                1. 3

                                  I cross the border every single day (not a citizen), and have only ever been brought in once. But I also don’t do anything that would be considered suspicious by anyone.?

                                  1. 11

                                    “I don’t mind <blank> because I have nothing to hide” is a slippery slope.

                                    1. 6

                                      I don’t think that @zzing is making that argument.

                                1. 3

                                  Is this meant to be ironic? All I see rendered is a blank white page with two URLs and a short orange line on it.

                                  1. 6

                                    Author here. Could you provide your OS and browser? I’ll look into a fix.

                                    1. 3

                                      Sure: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Firefox/45.0 on Debian Jessie with NoScript, but I whitelisted the site in NoScript.

                                      1. 6

                                        Should be fixed. Looks like it was a bug in the Fira Sans font itself.

                                    2. 5

                                      The problem is the web-font used in the article. Just overwrite the font-family-tag of <article> and the text is readable. A shame you have to go through this to read this article…

                                      A quick fix would be to run on the site:

                                      javascript:document.getElementsByTagName("article")[0].setAttribute("style", "font-family:Helvetica, Arial, sans-serif");
                                      1. 3

                                        Firefox lets you disable custom fonts for all sites via the UI settings. Chrome has an extension called ‘Disable Web Fonts’. Since I’ve disabled web fonts, I’ve found my web experience has generally improved.

                                        1. 1

                                          That worked; thanks. Whether the irony was intentional or not, it greatly amused me.