public override bool BeginNode(Node node) { CurrentNode = node; CodeElement codeElement = node.CodeElement; if (codeElement?.StorageAreaReads != null) { foreach (var storageAreaRead in codeElement.StorageAreaReads) { CheckVariable(node, storageAreaRead); } } if (codeElement?.StorageAreaWrites != null) { foreach (var storageAreaWrite in codeElement.StorageAreaWrites) { CheckVariable(node, storageAreaWrite.StorageArea); } } RedefinesChecker.OnNode(node); FunctionDeclarationChecker.OnNode(node); FunctionCallChecker.OnNode(node); TypedDeclarationChecker.OnNode(node); RenamesChecker.OnNode(node); ReadOnlyPropertiesChecker.OnNode(node); return(true); }
public override bool BeginNode(Node node) { CurrentNode = node; //Build node StorageAreaWritesDataDefinition and StorageAreaReadsDataDefinition dictionaries //from CodelElement StorageAreaReads and StorageAreaWrites CodeElement codeElement = node.CodeElement; if (codeElement?.StorageAreaReads != null) { foreach (var storageAreaRead in codeElement.StorageAreaReads) { CheckVariable(node, storageAreaRead, true); } } if (codeElement?.StorageAreaWrites != null) { foreach (var storageAreaWrite in codeElement.StorageAreaWrites) { CheckVariable(node, storageAreaWrite.StorageArea, false); } } //Build node StorageAreaWritesDataDefinition and StorageAreaReadsDataDefinition dictionaries //for Corresponding instruction from StorageAreaGroupsCorrespondingImpact if (codeElement?.StorageAreaGroupsCorrespondingImpact != null) { CheckVariable(node, codeElement.StorageAreaGroupsCorrespondingImpact.SendingGroupItem, true); CheckVariable(node, codeElement.StorageAreaGroupsCorrespondingImpact.ReceivingGroupItem, false); } RedefinesChecker <CodeElement> .OnNode(node); FunctionDeclarationChecker <CodeElement> .OnNode(node); FunctionCallChecker.OnNode(node); TypedDeclarationChecker.OnNode(node); RenamesChecker.OnNode(node); ReadOnlyPropertiesChecker.OnNode(node); return(true); }
public override bool BeginNode(Node node) { CodeElement codeElement = node.CodeElement; if (codeElement != null && codeElement.StorageAreaReads != null) { foreach (var storageAreaRead in codeElement.StorageAreaReads) { CheckVariable(node, storageAreaRead); } } if (codeElement != null && codeElement.StorageAreaWrites != null) { foreach (var storageAreaWrite in codeElement.StorageAreaWrites) { CheckVariable(node, storageAreaWrite); } } FunctionCallChecker.OnNode(node); TypedDeclarationChecker.OnNode(node); return(base.BeginNode(node)); }