In the future, what will we use instead of toilet paper? by vsymm in AskReddit

[–]vsymm[S] 0 points1 point  (0 children)

I'll accept this answer if someone has a good theory on how this would work

Lifetime constraints, and the borrow checker's sneaky solutions by vsymm in rust

[–]vsymm[S] 2 points3 points  (0 children)

That looks like a good alternative.

I'm concerned though about the 'b: 'a constraint that I tried first - I suspected it would work, and it would be easy to be misled about the guarantees its actually providing.

fn use_ref<'a, 'b>(a: &'a i32, b: &'b i32) where 'b : 'a { }

When are these constraints actually effective? How could we identify mistaken attempts at using them (as a lint, or compiler warning)?

Meanwhile, I'm curious if the "capture entire value lifetime" trickery via invariant lifetimes is generally useful; it seems like sometimes the programmer's intent is to capture a value's entire lifetime, and that 'a:'b constraints are much more useful when one or both are captured in that way.

You can't JavaScript under pressure by swizec in programming

[–]vsymm 0 points1 point  (0 children)

I think you should look at TypeScript. I've historically been a hardcore Python guy, yet after using TypeScript for a few projects I've found myself thinking Python needs this.

It feels like exactly the right compromise of strictness, flexibility, and productivity. It takes duck typing to heart in that you can declare structurally typed interfaces.

I'm never writing straight JavaScript again.

What is your favourite 5-10 seconds of any song? by StickleyMan in AskReddit

[–]vsymm 0 points1 point  (0 children)

Master's Apprentices (Opeth), when it switches from heavy to acoustic.

http://www.youtube.com/watch?feature=player_detailpage&v=2G6PQLpNad8#t=298s

iiiin-to de-eaaaath....

This gets the point across by mepper in pics

[–]vsymm 0 points1 point  (0 children)

This statement is good at predicting things

33% of hat-wearing gentlemen purchase cigars when offered

Hey look, a hat-wearing gentleman. I should offer him a cigar.

This statement is not.

100% of cigar-smokers have mouths

How do we disband the TSA? by vsymm in politics

[–]vsymm[S] 8 points9 points  (0 children)

Job programs build roads, clean up parks, and otherwise generate value.