Ah yes, separate software processes is probably the confusion here. Avoiding certain classes of deadlocks and hangs is also something that's not particularly guaranteed by imperative programs. You can throw a type system on it and get some of them (session types I think are quite expressive), but in practice I don't know of any imperative languages with a type system rich enough to do this.