Index: src/SymTab/Validate.cc
===================================================================
--- src/SymTab/Validate.cc	(revision 1485c1ae9cda2979dd9af8711f539c610c4c5b4b)
+++ src/SymTab/Validate.cc	(revision c470ada0207d9011922938be7cbc87f706da5ed5)
@@ -94,5 +94,5 @@
 		template< typename AggDecl > void handleAggregate( AggDecl *aggregateDecl );
 
-		bool inStruct = false;
+		AggregateDecl * parentAggr = nullptr;
 	};
 
@@ -303,10 +303,10 @@
 	template< typename AggDecl >
 	void HoistStruct::handleAggregate( AggDecl *aggregateDecl ) {
-		if ( inStruct ) {
+		if ( parentAggr ) {
 			// Add elements in stack order corresponding to nesting structure.
 			declsToAddBefore.push_front( aggregateDecl );
 		} else {
-			GuardValue( inStruct );
-			inStruct = true;
+			GuardValue( parentAggr );
+			parentAggr = aggregateDecl;
 		} // if
 		// Always remove the hoisted aggregate from the inner structure.
