Simplified TType class by carving out TStructure and TField.
R=kbr@chromium.org
Review URL: https://codereview.appspot.com/9866043
git-svn-id: https://angleproject.googlecode.com/svn/trunk@2423 736b8ea6-26fd-11df-bfd4-992fa37f6226
TRAC #23415
Authored-by: alokp@chromium.org
Signed-off-by: Shannon Woods
Signed-off-by Nicolas Capens
Merged-by: Jamie Madill
diff --git a/src/compiler/FlagStd140Structs.cpp b/src/compiler/FlagStd140Structs.cpp
index 1aaf50b..bcf33d2 100644
--- a/src/compiler/FlagStd140Structs.cpp
+++ b/src/compiler/FlagStd140Structs.cpp
@@ -55,11 +55,11 @@
const TType &type = node->getType();
- if (type.isInterfaceBlockMember() || type.getBasicType() == EbtInterfaceBlock)
+ // determine if we are in the standard layout
+ const TInterfaceBlock *interfaceBlock = type.getInterfaceBlock();
+ if (interfaceBlock)
{
- // determine if we are in the standard layout
- const TType &interfaceBlockType = (type.isInterfaceBlockMember() ? *type.getInterfaceBlockType() : type);
- return (interfaceBlockType.getLayoutQualifier().blockStorage == EbsStd140);
+ return (interfaceBlock->blockStorage() == EbsStd140);
}
return false;