From 9f411af73facb585e64858264b07eb7a56b3a923 Mon Sep 17 00:00:00 2001
From: Jake Wharton <jw@squareup.com>
Date: Mon, 17 Jun 2013 20:59:51 -0700
Subject: [PATCH] Update JavaWriter to v2.0.1.

---
 .../main/java/dagger/internal/codegen/GraphVizWriter.java   | 2 +-
 .../dagger/internal/codegen/InjectAdapterProcessor.java     | 6 +++---
 .../dagger/internal/codegen/ModuleAdapterProcessor.java     | 4 ++--
 pom.xml                                                     | 2 +-
 4 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/compiler/src/main/java/dagger/internal/codegen/GraphVizWriter.java b/compiler/src/main/java/dagger/internal/codegen/GraphVizWriter.java
index 519309e76d8..d149d167e94 100644
--- a/compiler/src/main/java/dagger/internal/codegen/GraphVizWriter.java
+++ b/compiler/src/main/java/dagger/internal/codegen/GraphVizWriter.java
@@ -15,7 +15,7 @@
  */
 package dagger.internal.codegen;
 
-import com.squareup.java.JavaWriter;
+import com.squareup.javawriter.JavaWriter;
 import java.io.Closeable;
 import java.io.IOException;
 import java.io.Writer;
diff --git a/compiler/src/main/java/dagger/internal/codegen/InjectAdapterProcessor.java b/compiler/src/main/java/dagger/internal/codegen/InjectAdapterProcessor.java
index de890dc0be5..cb47831d58f 100644
--- a/compiler/src/main/java/dagger/internal/codegen/InjectAdapterProcessor.java
+++ b/compiler/src/main/java/dagger/internal/codegen/InjectAdapterProcessor.java
@@ -15,7 +15,7 @@
  */
 package dagger.internal.codegen;
 
-import com.squareup.java.JavaWriter;
+import com.squareup.javawriter.JavaWriter;
 import dagger.MembersInjector;
 import dagger.internal.Binding;
 import dagger.internal.Linker;
@@ -239,7 +239,7 @@ private void writeInjectAdapter(TypeElement type, ExecutableElement constructor,
     boolean dependent = injectMembers
         || ((constructor != null) && !constructor.getParameters().isEmpty());
 
-    writer.emitEndOfLineComment(AdapterJavadocs.GENERATED_BY_DAGGER);
+    writer.emitSingleLineComment(AdapterJavadocs.GENERATED_BY_DAGGER);
     writer.emitPackage(packageName);
     writer.emitEmptyLine();
     writer.emitImports(getImports(dependent, injectMembers, constructor != null));
@@ -411,7 +411,7 @@ private void writeStaticInjection(TypeElement type, List<Element> fields) throws
         .createSourceFile(adapterName, type);
     JavaWriter writer = new JavaWriter(sourceFile.openWriter());
 
-    writer.emitEndOfLineComment(AdapterJavadocs.GENERATED_BY_DAGGER);
+    writer.emitSingleLineComment(AdapterJavadocs.GENERATED_BY_DAGGER);
     writer.emitPackage(getPackage(type).getQualifiedName().toString());
 
     writer.emitEmptyLine();
diff --git a/compiler/src/main/java/dagger/internal/codegen/ModuleAdapterProcessor.java b/compiler/src/main/java/dagger/internal/codegen/ModuleAdapterProcessor.java
index 420388d098a..1a814630f15 100644
--- a/compiler/src/main/java/dagger/internal/codegen/ModuleAdapterProcessor.java
+++ b/compiler/src/main/java/dagger/internal/codegen/ModuleAdapterProcessor.java
@@ -15,7 +15,7 @@
  */
 package dagger.internal.codegen;
 
-import com.squareup.java.JavaWriter;
+import com.squareup.javawriter.JavaWriter;
 import dagger.Module;
 import dagger.Provides;
 import dagger.internal.Binding;
@@ -231,7 +231,7 @@ private void writeModuleAdapter(TypeElement type, Map<String, Object> module,
     boolean multibindings = checkForMultibindings(providerMethods);
     boolean providerMethodDependencies = checkForDependencies(providerMethods);
 
-    writer.emitEndOfLineComment(AdapterJavadocs.GENERATED_BY_DAGGER);
+    writer.emitSingleLineComment(AdapterJavadocs.GENERATED_BY_DAGGER);
     writer.emitPackage(getPackage(type).getQualifiedName().toString());
     writer.emitEmptyLine();
     writer.emitImports(
diff --git a/pom.xml b/pom.xml
index 74e6f8b5c22..c1896334ca6 100644
--- a/pom.xml
+++ b/pom.xml
@@ -43,7 +43,7 @@
     <!-- Compilation -->
     <java.version>1.6</java.version>
     <javax.inject.version>1</javax.inject.version>
-    <javawriter.version>1.0.5</javawriter.version>
+    <javawriter.version>2.0.1</javawriter.version>
 
     <!-- Test Dependencies -->
     <junit.version>4.10</junit.version>