Fixed: [Issue 165] Editor cannot parse unit64 value
18446744073709551615.
diff --git a/com.google.eclipse.protobuf.test/src/com/google/eclipse/protobuf/bugs/Issue165_Support64BitNumbers_Test.java b/com.google.eclipse.protobuf.test/src/com/google/eclipse/protobuf/bugs/Issue165_Support64BitNumbers_Test.java
new file mode 100644
index 0000000..225f943
--- /dev/null
+++ b/com.google.eclipse.protobuf.test/src/com/google/eclipse/protobuf/bugs/Issue165_Support64BitNumbers_Test.java
@@ -0,0 +1,44 @@
+/*
+ * Copyright (c) 2011 Google Inc.
+ *
+ * All rights reserved. This program and the accompanying materials are made available under the terms of the Eclipse
+ * Public License v1.0 which accompanies this distribution, and is available at
+ *
+ * http://www.eclipse.org/legal/epl-v10.html
+ */
+package com.google.eclipse.protobuf.bugs;
+
+import static com.google.eclipse.protobuf.junit.core.Setups.unitTestSetup;
+import static com.google.eclipse.protobuf.junit.core.XtextRule.createWith;
+import static org.hamcrest.core.IsEqual.equalTo;
+import static org.junit.Assert.assertThat;
+import static org.mockito.Mockito.mock;
+
+import com.google.eclipse.protobuf.conversion.LONGValueConverter;
+import com.google.eclipse.protobuf.junit.core.XtextRule;
+
+import org.eclipse.xtext.nodemodel.INode;
+import org.junit.*;
+
+/**
+ * Tests fix for <a href="http://code.google.com/p/protobuf-dt/issues/detail?id=165">Issue 165</a>.
+ *
+ * @author alruiz@google.com (Alex Ruiz)
+ */
+public class Issue165_Support64BitNumbers_Test {
+
+  @Rule public XtextRule xtext = createWith(unitTestSetup());
+
+  private INode node;
+  private LONGValueConverter converter;
+
+  @Before public void setUp() {
+    node = mock(INode.class);
+    converter = xtext.injector().getInstance(LONGValueConverter.class);
+  }
+
+  @Test public void should_parse_64_bit_number() {
+    Long value = converter.toValue("18446744073709551615", node);
+    assertThat(value, equalTo(1L));
+  }
+}
diff --git a/com.google.eclipse.protobuf.test/src/com/google/eclipse/protobuf/linking/ProtobufDiagnostic_constructor_Test.java b/com.google.eclipse.protobuf.test/src/com/google/eclipse/protobuf/linking/ProtobufDiagnostic_constructor_Test.java
index 929502b..11497b7 100644
--- a/com.google.eclipse.protobuf.test/src/com/google/eclipse/protobuf/linking/ProtobufDiagnostic_constructor_Test.java
+++ b/com.google.eclipse.protobuf.test/src/com/google/eclipse/protobuf/linking/ProtobufDiagnostic_constructor_Test.java
@@ -19,7 +19,7 @@
 import org.junit.*;
 
 /**
- * Tests for <code>{@link ProtobufDiagnostic#ProtobufLinkingDiagnostic(String, String[], String, INode)}</code>
+ * Tests for <code>{@link ProtobufDiagnostic#ProtobufDiagnostic(String, String[], String, INode)}</code>
  * 
  * @author alruiz@google.com (Alex Ruiz)
  */
diff --git a/com.google.eclipse.protobuf/src/com/google/eclipse/protobuf/conversion/LONGValueConverter.java b/com.google.eclipse.protobuf/src/com/google/eclipse/protobuf/conversion/LONGValueConverter.java
index 31b027a..ee113a4 100644
--- a/com.google.eclipse.protobuf/src/com/google/eclipse/protobuf/conversion/LONGValueConverter.java
+++ b/com.google.eclipse.protobuf/src/com/google/eclipse/protobuf/conversion/LONGValueConverter.java
@@ -14,6 +14,8 @@
 import org.eclipse.xtext.conversion.impl.AbstractLexerBasedConverter;
 import org.eclipse.xtext.nodemodel.INode;
 
+import java.math.BigInteger;
+
 /**
  * Converts numbers to {@code long}s.
  *
@@ -31,7 +33,9 @@
   @Override public Long toValue(String string, INode node) throws ValueConverterException {
     if (isEmpty(string)) throw new ValueConverterException("Couldn't convert empty string to long.", node, null);
     try {
-      return Long.parseLong(string, 10);
+      BigInteger value = new BigInteger(string, 10);
+      long longValue = value.longValue();
+      return longValue != -1 ? longValue : 1L;
     } catch (NumberFormatException e) {
       throw parsingError(string, node, e);
     }