Viewing profile — pyrtsa
pyrtsa
HN member- Joined
- Wed, Sep 23, 2009, 9:14 PM UTC
- HN karma
- 93
- Public activity
- 29 items
- HN profile
- View on Hacker News ↗
About pyrtsa
My thoughts: http://pyrtsa.posterous.com
My tweets: http://twitter.com/pyrtsa
I write software for http://futurice.com in Helsinki, Finland, and study Engineering Physics and Computational Science at http://aalto.fi.
Recent public activity
-
comment
Comment #8147125
Nope, that's the funny feature of transducers. Like lenses in Haskell, transducers compose in reversed order. (sequence (comp (map inc) (filter even?)) (range 10)) ;;=> (2 4 6 8 10…
-
comment
Comment #6398653
But you'll need to document it very visibly that "Thou shalt call resource.close() whatever happened." C++ makes it possible for the library writer to take care of freeing the reso…
-
comment
Comment #6398632
Nitpick: if (x You shouldn't use `new` either when throwing exceptions. Just: if (x
-
comment
Comment #6398623
Bjarne's advice also applies to pointers wrapped as class members. There are just too many ways you can mess things up inside the class when dealing with raw pointers, examples inc…
-
comment
Comment #6255686
> This is neat, but really disappointing that there is no feedback when… Here's how you can say the same in a more positive manner: > This is neat, and it would be even better if t…
-
comment
Comment #5468368
I asked the same question in Twitter. Turns out James was actually augmenting (i.e. modifying) the array object `promises` to behave as a promise itself. I don't think this was a p…
-
comment
Comment #5240067
Correct. The key difference is that the enable_if version can be overloaded with mutually exclusive requirements: template typename enable_if ::type foo(int (&bar)[N]) { // called …
-
comment
Comment #5239484
And, by extending your second example, we can enforce the minimum array size with std::enable_if (C++11; boost::enable_if_c with C++03): template typename enable_if = 10), void>::t…
-
comment
Comment #4959254
In my view it's exactly the opposite: (-> (california) bay-in city-on) ; "The Californian bay's city" vs. (city-on (bay-in (california))) ; "The city on the bay in California" The …
- story
- story
-
comment
Comment #3177410
It might have been those UTF-8 ellipses: "…" Good to hear that you got it resolved, but are you sure that your character encoding settings are alright?
-
comment
Comment #3177318
Oh, good to hear. It's how Posterous implements the embedding of Github Gists that probably is to blame here. I'm still thinking whether to switch my blog to another platform, mayb…
- story
-
comment
Comment #3174258
I think the lambdas are the more useful the more complicated the function is. Simple asynchronous tasks might be one such example. This one, however, still is a pretty common use c…
-
comment
Comment #3174229
I don't think introducing more syntax to the language for a feature that ultimately is a library solution, is a sustainable way to go. But if you really need a compact notation for…
-
comment
Comment #3172513
Interesting. Previously, the same company has been behind the 3D view of Nokia's map service http://maps.nokia.com/3D/ — more info e.g. here http://www.ubergizmo.com/2011/04/c3-tec…
-
comment
Comment #3171609
Oh true, missed that. Finally pulled out the phone to realize this. And then the other option 16+20+20+20+16 / 32+40+40+40+32 already has too big a difference between the margins o…
-
comment
Comment #3171576
It's not impossible to make it symmetric for both, though. With consistent spacings. E.g. 19+18+18+18+19 (iPhone 3GS) 38+36+36+36+38 (iPhone 4)
-
comment
Comment #3165393
Anybody noticed how closely this, being from the programmer's point of view, is related to what Bret Victor [1] has been talking about from the UI perspective? Take http://worrydre…
- story
-
comment
Comment #3110242
Hmm, I think the months menu [1] that opens when you take the mouse to the bottom right corner should have months listed in the opposite order. It feels more logical to get the mos…
-
comment
Comment #2991509
Also, the Updates link on the bottom of the home page is broken, points to /update.php, not /updates.php like it should. ;)
-
comment
Comment #2921217
Seven years ago, maybe. But today's GPUs do it easily in their programmable pipeline (shaders). And where conditionals are costly, you can use tricks like: float temp = min(x, y); …
-
comment
Comment #2686797
Yeah, the hotel room analogy breaks as soon as you realize that visiting some completely other hotel room will already overwrite that variable in the first one. But it was a fun st…