You're looking at Less Wrong's discussion board. This includes all posts, including those that haven't been promoted to the front page yet. For more information, see About Less Wrong.

paper-machine comments on Question about application of Bayes - Less Wrong Discussion

0 Post author: RolfAndreassen 31 October 2012 02:35AM

You are viewing a comment permalink. View the original post to see all comments and the full post content.

Comments (30)

You are viewing a single comment's thread. Show more comments above.

Comment author: [deleted] 31 October 2012 04:15:01AM 2 points [-]

(This is why using C and C++ is usually a terrible idea, and why threads are so feared.)

I was with you up to this parenthetical. The same problems affect every other programming language, though perhaps with different root causes. Race conditions are hardly language-dependent.

Comment author: khafra 31 October 2012 01:38:28PM 3 points [-]

The probability of getting a race condition, given that you're programming in Haskell, is orders of magnitude lower than the probability of getting a race condition, given that you're programming in C or C++.

Comment author: RolfAndreassen 31 October 2012 05:14:48PM 0 points [-]

That may well be true. I do have some other constraints, though. For example, does Haskell have a well-supported GUI library that works on Windows and talks to OpenGL?

Comment author: khafra 31 October 2012 06:00:08PM 0 points [-]

Haskell requires bending your brain in ways that are often uncomfortable to non-mathematicians. I, personally, use Python, which strikes a balance between race avoidance and library support. I meant more to argue that race conditions are language-dependent than to recommend Haskell as a perfect programming language for any purpose.

Comment author: jimrandomh 31 October 2012 05:31:39AM *  3 points [-]

Not different root causes, fewer root causes. Threading problems and race conditions exist in all languages, but memory corruption does not; the majority of languages won't let you do things like write out of bounds or use after free.

Comment author: [deleted] 31 October 2012 06:25:49AM *  3 points [-]

Yes, memory corruption in particular is no longer an issue in most higher languages, but memory management in general has become more complicated and less transparent. The Law of Leaky Abstractions ruins everything.

In any case this is reasonably off-topic for this post, so I won't belabor the point further.