Fixes #42
diff --git a/lib/src/template_exception.dart b/lib/src/template_exception.dart
index 94db0a9..c1b24ce 100644
--- a/lib/src/template_exception.dart
+++ b/lib/src/template_exception.dart
@@ -51,7 +51,7 @@
     // Find line and character column.
     int lineNum = 1;
     int lineStart = 0;
-    bool lastWasCR;
+    bool lastWasCR = false;
     for (int i = 0; i < offset; i++) {
       int char = source.codeUnitAt(i);
       if (char == 0x0a) {