Silly code-style fixes
git-svn-id: https://google-guice.googlecode.com/svn/trunk@115 d779f126-a31b-0410-b53b-1d3aecad763e
diff --git a/src/com/google/inject/Scopes.java b/src/com/google/inject/Scopes.java
index b0b634c..86a6ca3 100644
--- a/src/com/google/inject/Scopes.java
+++ b/src/com/google/inject/Scopes.java
@@ -23,7 +23,8 @@
*/
public class Scopes {
- private Scopes() {}
+ private Scopes() {
+ }
/**
* Name of the default scope.
@@ -53,14 +54,16 @@
private volatile T instance;
- // DCL is safe as of Java 5, which we obviously require
+ // DCL on a volatile is safe as of Java 5, which we obviously require
@SuppressWarnings("DoubleCheckedLocking")
public T get() {
if (instance == null) {
- // Use a pretty coarse lock. We don't want to run into deadlocks
- // when two threads try to load circularly-dependent objects.
- // Maybe one of these days we will identify independent graphs of
- // objects and offer to load them in parallel.
+ /*
+ * Use a pretty coarse lock. We don't want to run into deadlocks
+ * when two threads try to load circularly-dependent objects.
+ * Maybe one of these days we will identify independent graphs of
+ * objects and offer to load them in parallel.
+ */
synchronized (Container.class) {
if (instance == null) {
instance = creator.get();
@@ -76,4 +79,4 @@
};
}
};
-}
\ No newline at end of file
+}