J
Joona I Palaste
Is there any difference at run-time, no matter how small, between this:
public synchronized void foo() {
/* ... */
}
and this:
public void foo() {
synchronized (this) {
/* ... */
}
}
?
--
/-- Joona Palaste ([email protected]) ---------------------------\
| Kingpriest of "The Flying Lemon Tree" G++ FR FW+ M- #108 D+ ADA N+++|
| http://www.helsinki.fi/~palaste W++ B OP+ |
\----------------------------------------- Finland rules! ------------/
"Bad things only happen to scoundrels."
- Moominmamma
public synchronized void foo() {
/* ... */
}
and this:
public void foo() {
synchronized (this) {
/* ... */
}
}
?
--
/-- Joona Palaste ([email protected]) ---------------------------\
| Kingpriest of "The Flying Lemon Tree" G++ FR FW+ M- #108 D+ ADA N+++|
| http://www.helsinki.fi/~palaste W++ B OP+ |
\----------------------------------------- Finland rules! ------------/
"Bad things only happen to scoundrels."
- Moominmamma