HN user

mercurial

6,385 karma

A mercurial software engineer.

Posts36
Comments2,398
View on HN
www.nytimes.com 10y ago

At a college in Kurdish Syria, Rojava tries to train its future leaders

mercurial
2pts0
danstillman.com 10y ago

Automated Scanning of Firefox Extensions Is Security Theater

mercurial
3pts0
jolla.com 10y ago

Jolla files for debt restructuring, lays off employee in December [pdf]

mercurial
1pts0
news.ycombinator.com 10y ago

Good JavaScript front end libraries?

mercurial
3pts3
blog.pgaddict.com 10y ago

Don't use BTRFS for OLTP

mercurial
18pts13
grsecurity.net 10y ago

Grsecurity stops making stable patches available

mercurial
1pts0
savetheinternet.eu 11y ago

Save the Internet – Defend Net Neutrality in Europe

mercurial
1pts0
www.the-open-mind.com 11y ago

The forgotten history of human zoos

mercurial
60pts29
arstechnica.com 11y ago

Europe reverses course on net neutrality legislation

mercurial
92pts46
www.haskellforall.com 11y ago

Morte: an intermediate language for super-optimizing functional programs

mercurial
79pts31
andrewray.github.io 11y ago

Experimental implicits for OCaml

mercurial
3pts0
caml.inria.fr 11y ago

OCaml 4.02.0 released

mercurial
3pts1
github.com 11y ago

Implementations of various type systems in OCaml

mercurial
113pts6
github.com 12y ago

Burn, a programming language coded in Rust

mercurial
2pts0
www.ledger-cli.org 12y ago

Ledger, a powerful CLI accounting tool

mercurial
124pts53
www.city-journal.org 12y ago

Who Is Fethullah Gülen?

mercurial
2pts0
en.wikipedia.org 12y ago

Paris syndrome

mercurial
3pts0
lists.debian.org 12y ago

Debian vote on init system ends with the outcome 'further discussion'

mercurial
2pts0
ocharles.org.uk 12y ago

How I Develop with Nix

mercurial
4pts0
www.bbc.co.uk 12y ago

'Revenge porn' website former owner Hunter Moore arrested

mercurial
137pts73
ocharles.org.uk 12y ago

24 Days of Hackage: pandoc

mercurial
64pts11
www.kickstarter.com 12y ago

Lavabit DarkMail kickstarter successfully funded

mercurial
3pts3
opinionator.blogs.nytimes.com 12y ago

Learning How to Die in the Anthropocene

mercurial
2pts0
arstechnica.com 12y ago

Mysterious Mac and PC malware that jumps airgaps?

mercurial
407pts246
www.independent.co.uk 12y ago

'Even worse than Foxconn': Apple rocked by child labour claims

mercurial
6pts0
arstechnica.com 12y ago

How playing casual games could help lead to better soldiers

mercurial
1pts0
math.andrej.com 12y ago

Eff, a language with an algebraic effect system

mercurial
2pts0
arstechnica.com 13y ago

Prenda seeded its own porn files via BitTorrent, new affidavit argues

mercurial
2pts0
jefferai.org 13y ago

Too Perfect a Mirror

mercurial
210pts125
www.kickstarter.com 13y ago

Torment sucessor kickstarter at $400,000 a few hours after starting

mercurial
4pts0

Short of using a different data structure, I'm not sure how you would get out of that one. The claim was that some of these leaks ("leaks"?) could be avoided by using a language with a GC. As far as I know, most modern languages' equivalent of Vec will do exactly the same thing, GC or not.

the pattern of allocating a vec as pseudo-RAM, using indices as pseudo-pointers, and never freeing anything till the container itself is unused

Are you talking about hand-rolled arena allocation? I don´t see how a GC language would have a different behaviour as long as you also use arena allocation and you keep a reachable reference.

There's nothing wrong with those techniques per se, but the language tends to paint you into a bit of a corner if you're not very good and very careful, so leaks are a fact of life in basically every major Rust project I've seen not written by somebody like BurntSushi

If I take 3 random major Rust projects like Serde, Hyper, and Tracing, none of which are written by BurntSushi, your claim is that they all suffer from memory leaks?

IMO, rustc_codegen_gcc is much more reasonable in scope. It also stands a chance of actually keeping up with subsequent Rust releases. I would be surprised if gcc-rs ever achieved any traction. Not to say it's not a fun project, but I can't see it replicating rustc.

Rust has a small(ish) but high quality stdlib. It does not aim to be Python. Like with any language, you have to know the ecosystem in order to be productive.

That said, sure, having a full-featured stdlib can be convenient. It's a matter of trade-offs. Having more content outside of the stdlib allows the ecosystem to evolve organically (and iterate quicker) and select the best approach to a given problem (which... could definitely have been an advantage for Python).

Wars are rarely won by single battles. That said, it really depends what period of history you are interested in. If you want to stick to the XXth century, Anthony Beevor regularly produces very readable books on WWII or the period immediately before (mostly concerned with the European theater).

If you are interested in more ancient history, I can warmly recommend Keagan's Peloponnesian War (which mostly draws on Thucydides eponymous masterwork).

Rust is a compiled language. There's a compile step when you make a code change.

That said, it really depends on what you're doing. If you are debugging something, it can be a bit painful but not terrible (typically, you're just changing a few things as you go along). If you're implementing a feature or refactoring, you're better served using "cargo check" (especially in combination with "cargo watch") to only run typechecking but not code generation, which means extremely fast feedback.

The .NET ecosystem is a lot more mature than Rust's, there is no arguing that. As for code cleanliness, though, it's debatable. Rust has ADTs, Option, exhaustive pattern matching, Option and Result. C# doesn't.

There is nothing particularly outstanding about C#'s type system. It has reified generics and some basic type constraints, but so what? No option type, no ADTs, no pattern matching... Working with Typescript at the same time, I feel crippled every time I need to do something in C#. Not that Typescript is perfact, but its type system (especially with `strict`) is considerably more sophisticated.

The article forgets to mention a crucial point: one of the Republicans' main reasons for not granting independence to Morocco was to avoid antagonizing the UK and France, who were major colonial powers. Throughout the war they hoped to gain their support. They never obtained it, which means they were pretty much hostages of the Stalin-backed communists, as the USSR was their main provider of arms and ammunition.

The strategy of the Stalin-backed communists was to not alienate the middle class. The anarchists, on the other hand, were not about letting war get in the way if social reform, and had taken over factories and collectivised land. It was also a good opportunity for Stalin to purge communists not allied with the USSR.

In this particular instance, clearly not. However, a rule of "first come first served" does not do anything but validate domain name squatting as a business model. It's like patents, you may have a patent linked to a legitimate business, or you may be in the extortion business. Let's not enable extortionists.

As for lifetimes, that syntax is from OCaml, though they use it for something else.

I hadn't noticed the similarity but it makes sense. This is the OCaml syntax for generics, eg:

    type 'a list_with_generic = 'a list;

At-will employment would have changed little about Roy’s situation vs a huge international political bully.

That entirely depends on the country. There is no "huge international bully" clause in employment law.

Not to mention that I'm not sure about "the real bully". If you think that underpaid customer care agents have the responsibility for executing your business strategy in China, maybe you should pay them appropriately. Or maybe you should ensure that someone higher up the food chain takes the fall.

Is an employee allowed to quit? What about the "violence" it does to the company, investors, and fellow employees? Must they stick around to provide continuity? If so, how is this not indenture?

Grotesque. Many industries in various countries have a reasonable notice period (say, 3 months), which should give the company enough time to adapt. Nobody considers this "indenture".

Employment represents a contract between two parties. Basic freedom of association and contract law means both parties can enter and leave under the terms they negotiate and have a rational self interest in acting in good faith.

The difference is that one party, most of the time, can manage without the other. On the other hand, the fired employee still needs to pay rent/feed his family. And depending on the economy/location, finding a different job might take some time (if it's possible at all without retraining).

Well, an order of magnitude of difference is a hint that, whatever the quality of the existing crates, there are definitely areas for which you are going to be hard-pressed to find a good solution (say, localization), or a solution at all.

It is not a sign that there is anything wrong with the Rust ecosystem, it has a very active community and things are moving in the right direction, it is not just as full-featured as more mature ecosystems out there.

See for instance https://github.com/ErichDonGubler/not-yet-awesome-rust

There are quite a few use cases not listed here, obviously.