Assuming I'm not using a lock statement, is this bad practice?
public static class Foo
{
public static string Bar()
{
bool working;
while (working)
{
}
working = true;
working = false;
return "done."
}
}
Edit -
Having tried something like this, I understand that this is not possible for several reasons. I was just curious. The example I wrote does not even work.
Ian p source
share