Merge pull request #39 from uburuntu/master

Some small fixes: compilation, null ptr derefence and const qualifiers
diff --git a/double-conversion/fixed-dtoa.cc b/double-conversion/fixed-dtoa.cc
index aef65fd..78378c5 100644
--- a/double-conversion/fixed-dtoa.cc
+++ b/double-conversion/fixed-dtoa.cc
@@ -98,7 +98,7 @@
     return high_bits_ == 0 && low_bits_ == 0;
   }
 
-  int BitAt(int position) {
+  int BitAt(int position) const {
     if (position >= 64) {
       return static_cast<int>(high_bits_ >> (position - 64)) & 1;
     } else {
diff --git a/double-conversion/ieee.h b/double-conversion/ieee.h
index 661141d..b14cf4f 100644
--- a/double-conversion/ieee.h
+++ b/double-conversion/ieee.h
@@ -99,7 +99,7 @@
   }
 
   double PreviousDouble() const {
-    if (d64_ == (kInfinity | kSignMask)) return -Double::Infinity();
+    if (d64_ == (kInfinity | kSignMask)) return -Infinity();
     if (Sign() < 0) {
       return Double(d64_ + 1).value();
     } else {
diff --git a/test/cctest/cctest.h b/test/cctest/cctest.h
index cb87076..bd157a6 100644
--- a/test/cctest/cctest.h
+++ b/test/cctest/cctest.h
@@ -75,8 +75,11 @@
                                      const char* value_source,
                                      const char* value) {
   if ((expected == NULL && value != NULL) ||
-      (expected != NULL && value == NULL) ||
-      (expected != NULL && value != NULL && strcmp(expected, value) != 0)) {
+      (expected != NULL && value == NULL)) {
+    abort();
+  }
+
+  if ((expected != NULL && value != NULL && strcmp(expected, value) != 0)) {
     printf("%s:%d:\n CHECK_EQ(%s, %s) failed\n"
            "#  Expected: %s\n"
            "#  Found:    %s\n",
@@ -124,10 +127,10 @@
   static int test_count();
   static CcTest* last() { return last_; }
   CcTest* prev() { return prev_; }
-  const char* file() { return file_; }
-  const char* name() { return name_; }
-  const char* dependency() { return dependency_; }
-  bool enabled() { return enabled_; }
+  const char* file() const { return file_; }
+  const char* name() const { return name_; }
+  const char* dependency() const { return dependency_; }
+  bool enabled() const { return enabled_; }
  private:
   TestFunction* callback_;
   const char* file_;