More testcases for multibindings, including some fairly specific tests for toString() on the Binder API

git-svn-id: https://google-guice.googlecode.com/svn/trunk@483 d779f126-a31b-0410-b53b-1d3aecad763e
diff --git a/src/com/google/inject/BindCommandProcessor.java b/src/com/google/inject/BindCommandProcessor.java
index 59db4b9..008f6c8 100644
--- a/src/com/google/inject/BindCommandProcessor.java
+++ b/src/com/google/inject/BindCommandProcessor.java
@@ -209,11 +209,13 @@
   }
 
   @Override public Boolean visitBindConstant(BindConstantCommand command) {
-    Object value = command.getTarget().get();
-    if (value == null) {
+    BindTarget<?> target = command.getTarget();
+    if (target == null) {
       addError(command.getSource(), ErrorMessages.MISSING_CONSTANT_VALUE);
+      return true;
     }
 
+    Object value = target.get();
     validateKey(command.getSource(), command.getKey());
     ConstantFactory<Object> factory = new ConstantFactory<Object>(value);
     putBinding(new ConstantBindingImpl<Object>(