diff --git a/indra/llcommon/llpointer.h b/indra/llcommon/llpointer.h
index e640ffd5950b194b1b5dc91a87b2ce0e45b6b49a..6a0a8fcb0d9cdb91332d48bfbcf60bfae13dff04 100755
--- a/indra/llcommon/llpointer.h
+++ b/indra/llcommon/llpointer.h
@@ -193,7 +193,7 @@ class LLCopyOnWritePointer : public LLPointer<Type>
 	{
 		if (pointer_t::notNull() && pointer_t::mPointer->getNumRefs() > 1)
 		{
-			*(pointer_t*)(this) = new Type(*pointer_t::mPointer);
+			*(pointer_t* )(this) = new Type(*pointer_t::mPointer);
 		}
 	}
 
diff --git a/indra/llcommon/lltrace.h b/indra/llcommon/lltrace.h
index 343e1b16e80d1d8c9e96f207d24734f0966797c8..c20e836f775f0626bac07fc7da452e9e891b2232 100644
--- a/indra/llcommon/lltrace.h
+++ b/indra/llcommon/lltrace.h
@@ -657,7 +657,7 @@ class EventStatHandle
 :	public TraceType<EventAccumulator>
 {
 public:
-	typedef typename F64 storage_t;
+	typedef F64 storage_t;
 	typedef TraceType<EventAccumulator> trace_t;
 
 	EventStatHandle(const char* name, const char* description = NULL)
@@ -702,7 +702,7 @@ class CountStatHandle
 :	public TraceType<CountAccumulator>
 {
 public:
-	typedef typename F64 storage_t;
+	typedef F64 storage_t;
 	typedef TraceType<CountAccumulator> trace_t;
 
 	CountStatHandle(const char* name, const char* description = NULL) 
diff --git a/indra/llcommon/llunit.h b/indra/llcommon/llunit.h
index a5406fb3f01fac9ece4931fec1812bd4c7ecbc6e..f48cbe0e11ffeb29edc3c81f011978e0a0a4f4c9 100644
--- a/indra/llcommon/llunit.h
+++ b/indra/llcommon/llunit.h
@@ -41,6 +41,7 @@ struct ConversionFactor
 	{
 		// spurious use of dependent type to stop gcc from triggering the static assertion before instantiating the template
 		llstatic_assert_template(DERIVED_UNITS_TAG, false,  "Cannot convert between types.");
+        return 0;
 	}
 };
 
@@ -473,7 +474,7 @@ LL_DECLARE_DERIVED_UNIT(1000 * 1000, Hertz, Megahertz, "MHz");
 LL_DECLARE_DERIVED_UNIT(1000 * 1000 * 1000, Hertz, Gigahertz, "GHz");
 
 LL_DECLARE_BASE_UNIT(Radians, "rad");
-LL_DECLARE_DERIVED_UNIT(DEG_TO_RAD, Radians, Degrees, "deg");
+LL_DECLARE_DERIVED_UNIT(0.01745329251994, Radians, Degrees, "deg");
 
 
 } // namespace LLUnits
diff --git a/indra/llcommon/tests/llunits_test.cpp b/indra/llcommon/tests/llunits_test.cpp
index 2a941e8229b8071b90300b8eb10796a27f6c41e7..33e30f9688c87f90cd7647cbc76d4ac1d0f20f03 100644
--- a/indra/llcommon/tests/llunits_test.cpp
+++ b/indra/llcommon/tests/llunits_test.cpp
@@ -33,9 +33,9 @@
 namespace LLUnits
 {
 	// using powers of 2 to allow strict floating point equality
-	struct Quatloos { typedef Quatloos base_unit_t; };
-	LL_DECLARE_DERIVED_UNIT(4, Quatloos, Latinum);
-	LL_DECLARE_DERIVED_UNIT((1.0 / 4.0), Quatloos, Solari);
+	LL_DECLARE_BASE_UNIT(Quatloos, "Quat");
+	LL_DECLARE_DERIVED_UNIT(4, Quatloos, Latinum, "Lat");
+	LL_DECLARE_DERIVED_UNIT((1.0 / 4.0), Quatloos, Solari, "Sol");
 }
 
 namespace tut