HNHacker News
TopNewBestAskShowJobs

slashnull

224 karma · joined December 17, 2013

submissionscomments
slashnull··on Facebook Launches Flow, Static Type Checker for JavaScript
I suppose he was talking about TypeScript and CoffeeScript.
slashnull··on Facebook Launches Flow, Static Type Checker for JavaScript
I like to think that static typing haven't delivered its promises because the current statically typed languages and toolage is inappropriate and immature, but I realize that this might be a symptom of the Smug LISP Weenie syndrome that affects me.
slashnull··on Facebook Launches Flow, Static Type Checker for JavaScript
So what's wrong with having a tool to automate those practices ; )
slashnull··on Facebook Launches Flow, Static Type Checker for JavaScript
It's pretty much a bastardized form of HM typing, like Haskell, OCaml and ML has.

http://learnyouahaskell.com/

slashnull··on Facebook Launches Flow, Static Type Checker for JavaScript
Well yeah nobody talked about removing JS's duck typing algo.
slashnull··on Facebook Launches Flow, Static Type Checker for JavaScript
I don't want to say what I'm about to say, but...

I don't care about the type signature of promises. I actually don't care about the type of anything which has a complicated type; I think it's just incredibly winning that I will now be able to describe the shape of the raw data circulating in my code.

I've always found really annoying, in Haskell, to see incredibly complex type idioms emerging to allow stuff that doesn't really deserve it. And yes, I'm talking about monad transformers.

Don't get me wrong, I think that Haskell and the typing techniques and idioms it has fostered are a tremendous achievement, but right now, I'm more focused on bringing my web code, which right now is unfortunately a jungle of implicitly-typed garbage, closer to a safe and predictable better-typed form.

I tried to do that in Haskell in the back-end, but everytime I tried, I lost mind-boggling amounts of time dealing with the monadic stack of the framework I tried.

As the saying goes, I'm not clever enough to use dynamic typing, and bugs happen. Unfortunately, I'm also not clever enough to use real strong typing, and nothing compiles, let alone gets done.

Hence why I'm immensely thankful to see facebook embracing gradual typing in a way that lets me leverage my knowledge of algebraic typing.

slashnull··on Facebook Launches Flow, Static Type Checker for JavaScript
Wow!

I missed the part about sum types!

My god this is perfect

slashnull··on Facebook Launches Flow, Static Type Checker for JavaScript
If only to remove syntactically invalid type annotations, I guess. Strong typing is not incompatible with the absence of run-time typing information, due to the magic of type erasure.
slashnull··on Facebook Launches Flow, Static Type Checker for JavaScript
At last!

This all seem extremely cool.

I went straight from hacking Scala and Haskell as a hobbyist to doing (mostly) front-end JS job, and I've always found that my code, and a lot of good libraries I read, naturally emulate something close to Hindley-Milner typing, by using objects as tuples/records and arrays as (hopefully well-typed) lists, as well as the natural flexibility of objects as a poor substitute for Either types.

I'm definitely pleased to see that the designers of this library have also realized that strongly-typed javascript was just a few annotations and a type inference algorithm away.

I'm just wondering why are nullable types inmplemented as such and not as a natural consequence of full sum types, which are inexplicably absent.

slashnull··on If you were teaching a programming course, what language would you teach it in?
JavaScript for beginners, Haskell for advanced.
slashnull··on How many of you use a Linux distro as your primary desktop OS?
Really at this point it's fair to say the the current Linux desktop stack is already a miracle; a backwards-incompatible rebuild is just impossible, or at least with the current state of the mainstream UI development tools.

Which, on the other hand, I think is rapidly evolving, now that OOP is out of its hype phase, and can now be evaluated a bit more (pun almost intended) objectively, and freed from its unnecessary parts, and that front-end JS and functional reactive techniques are bringing new ideas and especially terse and powerful notations and abstractions to describe UI layouts and interactions, to the table.

One can dream of an invention-of-the-C-language-like situation where a team of lone hackers harness the power of a bump in expressive power to formalize the current state of their UI metaphors and reimplement it from scratch and then build upon that at tremendous (relative) speeds...

Well, I dream.

Futzing with front-end JS frameworks is having unexpected effects on my worldview, right now.

slashnull··on How many of you use a Linux distro as your primary desktop OS?
What distro did you start with? Mostly I had trouble with setting up JACK.

Then, I have to admit, I didn't make it easy for myself; I tried to use SuperCollider, which worked... Somewhat, until I nerded out and tried to speak to it from within Haskell.

I'm really tempted by Renoise, though.

slashnull··on How many of you use a Linux distro as your primary desktop OS?
Okay, I used Ableton on Win7 for a while, and tried to keep making music when I made the switch to Linux, and so far (after 3 years of on-and-off effort) it's been a complete and total failure for me, and I don't know anyone making non-experimental electronic music on Linux.

I'd like to know more about your setup.

slashnull··on How many of you use a Linux distro as your primary desktop OS?
Debian.

1) the customization options (tiling WMs ftw)

2) the ease of replicating the production environment I work with

3) the package managers

4) the everything-is-an-ascii-stream metaphor and the ease of creating and using tiny, tiny executables (e.g. shell scripts, daemons, composable cli utils, etc)

5) the complete and total freedom to install and use whatever I want, whenever I want without ever having to pay for anything at all, and more importantly ever have to ever think about entering a product key or having to register anything.

6) the tiny, tiny performance requirements and extremely wide hardware support

7) the networking toolage (ssh, curl, wget, scp, rsync, etc being either already there or one apt-get away)

8) the general feeling that complicated things are abstracted away only if it's possible to do so. The fact that things break transparently, or at least more transparently than the competition. The fact that it's beneficial to Debian that failures and shortcomings be discussed publicly and at length rather than being held behind closed doors to maintain a credible commercial image.

I would really like it if some OS could re-implement the, as I said, everything-as-an-UTF8-stream w/ networking as a first-class citizen, the blank slate UI to be built from scratch (and a few shells), while shedding the legacy crud of teletype-era in-band signaling keycodes, the X window systems, and so on, which I admit is very, very unlikely as it implies re-implementing almost all of the stack, at once, in a backward-incompatible way, all to re-implement a model (the CLI) that is seen as a technical relic to almost everybody except me and Neal Stephenson.

Let's just say, then, that I will switch OS when someone will be offering a consistent, minimal and usable UI metaphor, while accomodating the motor tics I developed using Vim for the last few years.

slashnull··on Announcing Soylent 1.2
I'm hungry
slashnull··on Spaghetti stacks
Followed by The Closure Chronicles: jesus christ the Chicken Scheme garbage collector is mind-blowing: the blogpost
slashnull··on Spaghetti stacks
Followed by Closures are Weird The Third Installment Episode Two: Everyday I am sitting on the shoulders of Scheme giants: the Steve Yegge wall of text
slashnull··on Spaghetti stacks
Followed by Closures are Weird The Third Installment Episode One: the Golden Era of LISP AI Research: the Rambling Usenet Post
slashnull··on Spaghetti stacks
Followed by Closures are weird The Third Installment: continuations are life, continuations are love: the c2 entry
slashnull··on Spaghetti stacks
Followed by Closures are weird part deux: what the hell are downward funargs?: the Stackoverflow thread
slashnull··on Spaghetti stacks
Closures are weird: the Wikipedia article
slashnull··on All that’s great about CoffeeScript in 40 characters
Ah yes the argument by neat one-liner.

Now let's move on to the truly relevant and constructive activity: comparing which language has best-looking toy quicksort implementation

slashnull··on Innovations For Poor Farmers
A cheap, reliable, simple milk jug design, mass-produced until the marginal cost just vanishes.

Educational fucking videos. Understanding the conditions where food is cultivated. Growing stronger crops.

This is just beautifully simple, realistic and down-to-earth.

slashnull··on The Magical Number Seven, Plus or Minus Two
Too lazy, but you can just google "miller magic number" and it explains to you that we can remember 7 +- 2 elements at the same time and discusses a few implications, such as phone numbers having 7 digits.
slashnull··on The Magical Number Seven, Plus or Minus Two
Mine is approximately half of that.

Eagerly awaiting artificial memory implants. 'l be the first in line.

slashnull··on Puer – more than a live-reload server, built for efficient front end development
Fais le!
slashnull··on Puer – more than a live-reload server, built for efficient front end development
It's also the french for "to stink"

... Sorry

slashnull··on Haskell Is Exceptionally Unsafe (2012)
After a year or so of near constant dependency hell problems with Haskell, I stabilized all my setups on GHC7.8.3 and the associated Stackage inclusive, and it all... just... works...

I can finally go and write some relevant code now.

slashnull··on What Organized Crime Pays
Also, find . -name "*.swp" -exec rm {} \; is also slowly getting abstracted away in my mind as a single, atomic and very useful command.
slashnull··on What Organized Crime Pays
truth
← PreviousPage 4 of 7Next →