HNHacker News
TopNewBestAskShowJobs

emillon

2,853 karma · joined January 10, 2011

Paris-based λ-term writer.

    https://github.com/emillon/
    http://blog.emillon.org/
    @etiennemillon
    me @ <username> . org
submissionscomments
emillon··on Linux is not about choice (2008)
Edited, thanks.
emillon··on [dead]
This is a distinctive feature of thedailywtf articles.
emillon··on Debian 7.0 "Wheezy" released
FYI, the less/man-db issue is tracked here:

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=695361

emillon··on Let's Make GitHub Better, Together
They could still sell support. The "open source, closed addons, paying support" business model can work great (Red Hat, VMWare, certain Oracle products...).
emillon··on Why is printf better than echo?
> On those echo that support options, there's generally no support of a -- to mark the end of options (zsh and possibly others support - for that though), so for instance, it's difficult to output "-n" in many shells.

It's good to know (while the key takeaway lesson is "use printf"):

    # bash
    $ echo -n
    $ echo -- -n
    -- -n
    $ echo - -n
    - -n

    # zsh
    $ echo -n
    $ echo -- -n
    -- -n
    $ echo - -n
    -n
emillon··on A French love affair... with graphology
It is becoming very, very rare. Given that the source for the 50% figure is graphologists, I wouldn't give it too much credit. As a french person, last time I heard about someone that needed a handwritten cover letter was in the early 2000s. At least in the tech circles this is definitely something unseen.
emillon··on How To Opt Out of Facebook Ads Based on Your Real-Life Shopping Activity
You can block it on your router.
emillon··on JQuery Annotated Source
It's similar to literate programming, which consists in exchanging the focus between code and comments. I believe that Coffeescript just got a literate processor, so the community may benefit from this in the near future. Because GHC supports it, it is also very popular in the Haskell community.
emillon··on “What part of Milner-Hindley do you not understand?”
In the presence of polymorphism and mutable cells, value restriction (or a restriction thereof) is necessary to establish type soundness (ie that typed programs are safe), so I'd argue that it achieves this goal.

As for this explanation, I'm not entirely convinced. In the first example, seeing x as two different cells depending on the type is interesting, but I have trouble seeing how it is possible to express its semantics without keeping runtime type information. Is System F compatible with type erasure?

emillon··on “What part of Milner-Hindley do you not understand?”
I was not totally right in the my "uncle" comment. It has to do with the value restriction in the sense that it is where the distinction occurs (lambdas are never genezalized ; let-bindings are generalized for values), but the original HM system (without refs) indeed made this distinction.

I believe that if you don't do it and generalize everywhere, unification of types is harder or even impossible because everything has a type scheme.

This would look a lot like System F, for which type inference is undecidable, for example.

emillon··on “What part of Milner-Hindley do you not understand?”
Yes. For example, if you generalize reference values, you can type ref [] as ∀a. (a list) ref, then store [4] to it, then retrieve a float from the head of the stored list, thus breaking the type system. It is a bit similar to array type variance problem that struck Java. One solution is to distinguish between syntactic forms that may allocate memory (eg, function applications) and the ones that can not (eg, abstractions, constants, variables), and only generalize the latter ones.

(Operationally speaking, the two forms (let and abs+app) are always equivalent, though).

emillon··on “What part of Milner-Hindley do you not understand?”
Hindley-Milner (never seen it written as M-H) is beautiful because it's an elegant extension of simply-typed lambda calculus (STLC) that brings a very useful trait, polymorphism.

Here the first 3 rules are those of STLC. The magic happens in [Gen] and [Inst]: namely, you can generalize free type variables. If you have a function that works on lists of elements of type t when there is no constraint on t, they can work on any lists of any type. This brings quantification to the type system, ie you go from:

    ∀ a. reverse : α list → α list
to

    reverse : ∀ α. α list → α list
(in the first one, ∀ is part of the discourse, and in the second one, part of the type). [Inst] states that you can replace a quantified variable by any variable. This is the role of the ⊑ operator, which is unfortunately not explained in this notation. This is confusing for people not used to type systems, ie most people).

Technically, [Let] is redundant because it is a combination of [App]+[Abs] : let x = e1 in e2 is equivalent to (λx.e2) e1. There is a difference in the ML branch of languages (as opposed to the Haskell branch) because in the presence of memory references (mutable cells) you can't generalize everywhere, so only let-bound variables are given a type scheme σ (both in the let...in construct and in toplevel phrases). That's why there is usually an explicit generalisation step at this point. Or maybe I have overlooked this particular presentation. HTH

emillon··on Hacking Flask: A Success Story
Shouldn't the super call be:

    super(MyFancyRequestHandler, self).send_response(code, message=message)
instead of:

    super(MyFancyRequestHandler, self).send_response(code, message=None)
(or even better, with args and kwargs)? Otherwise it seems that the message is discarded and None is always passed. This is one of the places where python's syntax is awful IMHO. Setting a default value shouldn't be the same as passing a parameter.
emillon··on 250,000 English words currently available as Twitter handles
Thanks ! Just, you're missing a "print" and single quotes would work better :)
emillon··on Improving the Fedora boot experience
> the X server won't start until runlevel 5

I don't think that the runlevel numbers are sequential. You can switch between levels (and that corresponds to more or less services running) but you pretty much boot directly to runlevel 5.

Within a runlevel, services are ordered, though (either by an arbitrary integer or by dependency).

emillon··on Vim Splits – Move Faster and More Naturally
or `, delete, e if digraphs are activated (IIRC)
emillon··on How to Slice a Bagel into Two Linked Halves
This construction shows Villarceau circles[1], which are the nontrivial circle sections of a torus. This can be also seen on the POV raytracer hall of fame[2].

    [1]: http://en.wikipedia.org/wiki/Villarceau_circles
    [2]: http://hof.povray.org/Villarceau_Circles-CSG.html
emillon··on New Debian Project Leader elected: Lucas Nussbaum
The DPL is elected among Debian Developers using a Condorcet method. Every voter gives a preference order between the candidates[1], and if there exists a candidate who would win against any other candidate, he's the winner. For example here is the graph of this election[2].

[1]: http://vote.debian.org/~secretary/leader2013/tally.txt [2]: http://vote.debian.org/~secretary/leader2013/results.png

emillon··on Keep TODOs in git
For that purpose I use ticgit which creates an unrelated branch in a git repository to store data. There's even a web client if you want to go fancy.

https://github.com/schacon/ticgit

emillon··on Some decompiling, reverse engineering, and keygen tutorials
It is also windows only.
emillon··on Common words translation sheet for indie game developers.
For a self-hosted translation management system, you can have a look at weblate :

http://weblate.org/

emillon··on A Better To-Do List: The 1-3-5 Rule
Neat !

Small remark: the github link does not work (it has an extra .github.com).

emillon··on PythonMonk – Learn Python in the browser
Execv'ing processes is OK as long as you don't fork:

    __import__("os").execv("/usr/bin/uname", ["uname", "-a"])
    Linux ip-10-196-3-111 2.6.32-amazon-xen-r3 #1 SMP Mon Jan 16 21:03:16 PST 2012 i686 GNU/Linux
As for the actual files, there are a few clues that a chroot is created for every request : /proc is not mounted, /etc is minimal (root + 1 user in passwd) and "ls -id /" returns a new inode number every time.
emillon··on PythonMonk – Learn Python in the browser
This particular behaviour can occur because the process is disallowed to call fork() and can be done with setrlimit() (see RLIMIT_NPROC). There should be other protections, though, because forking a "ls" is not the only way to access the filesystem.
emillon··on Valve's GDC Talk: Porting Source to Linux [pdf]
There's also gdbtui which is built-in (gdb -tui or "layout next" when in a gdb session) and not too bad to at least view the code and type commands at the same time.
emillon··on Rebuild code automatically with "watch" and a makefile
I use separate screens. Usually I have one terminal for vim and one terminal with a shell for make, git, etc. Using this setup and a tiling window manager, I can see the build log whenever I type :w.
emillon··on Rebuild code automatically with "watch" and a makefile
This will stop trying to build at the first compile error.
emillon··on Rebuild code automatically with "watch" and a makefile
On linux you can use inotify to avoid polling. I use such a rule for my makefiles :

    watch:
        while true ; do inotifywait -qe close_write $(SRC); $(MAKE) ; done
emillon··on Next Big Thing, a HN-like site for music content
Closest you can find is news.arc, for example see a mirror on [1]. The canonical source should be in the arc distribution.

[1]: https://github.com/wting/hackernews/blob/master/news.arc

emillon··on Linux Mint Debian 201303 released
> I think Ubuntu actually takes the Testing packages anyway.

The automatic synchronization actually picks from unstable. Not that it changes a lot, because the majority of packages end up migrating. I'm not too familiar with the ubuntu processes, but I assume that if the next ubuntu release contains uninstallable packages (or other things that can happen in unstable but should not in testing), they reimport a later package.

← PreviousPage 6 of 11Next →