Is it just me or does the Go community use a different definition of "concurrency" vs "parallelism"? The "standard" one is afaict "parallelism is one way of getting concurrency", whereas Go seems to use it specifically to talk about interleaving.
-
-
I primarily write JavaScript. Mostly frontend development.
-
Javascript is concurrent but not parallel in a single worker. Web workers make JS parallel. In JS tasks are interleaved but a single unit of execution (like adding two numbers) won't run in parallel with another. Unless that's in a web worker.
-
Though in JS specifically the unit of execution spans the entire task in the event loop (i.e. the entire set of non-async non-callback code you wrote). Async code lets you write a series of tasks as a single unit easily.
-
When we say "making progress at the same time", it means that there is a point in time at which both tasks are at partial progress. I.e. we don't just run them one after the other, there's interleaving.
End of conversation
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.