This is Twey's Typepad Profile.
Join Typepad and start following Twey's activity
Join Now!
Already a member? Sign In
Twey
Recent Activity
No, Javascript does not use multiple threads, and so programming ‘concurrency’ in Javascript is greatly simplified — your ‘other thread’ is guaranteed to run only when no other code is running, so you don't have to worry about it executing after a check, or halfway through a statement, or during an assignment, or part-way through a procedure. I think the general consensus is simply that imperative programming is fundamentally the wrong paradigm for dealing with concurrent applications. Functional (and semi-functional — Erlang) languages are making leaps and bounds in this area (such as Erlang's actor model, or Haskell's STM), while ‘traditional’ imperative languages seem to have reached a local maximum. Concurrency in these models does still require some thought, but overall I would say that there are a lot less opportunities for horrible bugs to slip in.