add template macro to "safely" perform casts w/o breaking strict-aliasing
fix aliasing warnings



git-svn-id: http://skia.googlecode.com/svn/trunk@674 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/src/gpu/SkGpuDevice.cpp b/src/gpu/SkGpuDevice.cpp
index 7c50ab3..2d5634c 100644
--- a/src/gpu/SkGpuDevice.cpp
+++ b/src/gpu/SkGpuDevice.cpp
@@ -711,7 +711,7 @@
 
     GrPoint* vertex;
     if (!fContext->reserveAndLockGeometry(layout, 4,
-                                          0, (void**)&vertex, NULL)) {
+                                          0, GrTCast<void**>(&vertex), NULL)) {
         return;
     }
 
@@ -750,7 +750,8 @@
 
     GrPoint* vertex;
     GrVertexLayout layout = GrGpu::kSeparateTexCoord_VertexLayoutBit;
-    if (!ctx->reserveAndLockGeometry(layout, 4, 0, (void**)&vertex, NULL)) {
+    if (!ctx->reserveAndLockGeometry(layout, 4, 0,
+                                     GrTCast<void**>(&vertex), NULL)) {
         return;
     }