aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar bsalomon@google.com <bsalomon@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2012-05-21 15:31:00 +0000
committerGravatar bsalomon@google.com <bsalomon@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2012-05-21 15:31:00 +0000
commit7c4d06de413dc759a81c34aca1178fa4c5963b0b (patch)
treea2dfcf027d65b00bd0dfbcc692e9f2f048a225ca
parent7b578928a5705f40cfe051ae1c41c1b2e1df0bdd (diff)
Make static const var that is only used in an assert be defined in the debug build only to suppress an unused var warning.
git-svn-id: http://skia.googlecode.com/svn/trunk@4012 2bbb7eff-a529-9590-31e7-b0007b416f81
-rw-r--r--include/gpu/GrProgramStageFactory.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/gpu/GrProgramStageFactory.h b/include/gpu/GrProgramStageFactory.h
index dcf7cf21d1..e5f05f74d5 100644
--- a/include/gpu/GrProgramStageFactory.h
+++ b/include/gpu/GrProgramStageFactory.h
@@ -75,9 +75,11 @@ public:
virtual StageKey stageKey(const GrCustomStage* stage) const SK_OVERRIDE {
GrAssert(kIllegalStageClassID != fStageClassID);
StageKey stageID = GLProgramStage::GenKey(stage);
+#if GR_DEBUG
static const StageKey kIllegalIDMask =
~((1 << kProgramStageKeyBits) - 1);
GrAssert(!(kIllegalIDMask & stageID));
+#endif
return fStageClassID | stageID;
}