[RFC] "lock" statement and "mutex" type.

Dejan Lekic dejan at nu6.org
Tue Mar 14 14:54:22 PST 2006


I think D should have mutex type and lock statement as part of D language,
in the similar fashion as in Modula-3.

D programmer would than be able to write:

mutex myMutex;

lock (myMutex)
{
  doSomething();
} else {
  continueSomething();
}

What do others think about this?
Reason for this above is that my personal opinion is that D should be the
language with full support for threads. I would even add "thread" keyword
somehow...

Kind regards

Dejan



More information about the Digitalmars-d mailing list