Ejemplo n.º 1
0
 def _analyze(self, oFile, oLine, iLineNumber):
     if oLine.isSequential:
         if not oLine.isSequentialEnd:
             self.iAlignmentColumn = oLine.line.find('<=') + len('<= ')
     if oLine.insideSequential and not oLine.isComment and not oLine.isSequential:
         check.multiline_alignment(self, self.iAlignmentColumn, oLine,
                                   iLineNumber)
Ejemplo n.º 2
0
 def _analyze(self, oFile, oLine, iLineNumber):
     if oLine.isCaseWhenKeyword:
         if not oLine.isCaseWhenEnd:
             self.iAlignmentColumn = (oLine.indentLevel *
                                      self.indentSize) + len('when ')
     elif oLine.insideCaseWhen:
         check.multiline_alignment(self, self.iAlignmentColumn, oLine,
                                   iLineNumber)
Ejemplo n.º 3
0
 def _analyze(self, oFile, oLine, iLineNumber):
     if oLine.insideConcurrent:
         if oLine.isConcurrentBegin:
             if not oLine.isEndConcurrent:
                 self.iAlignmentColumn = oLine.line.find('<') + 3
         else:
             check.multiline_alignment(self, self.iAlignmentColumn, oLine,
                                       iLineNumber)
Ejemplo n.º 4
0
 def analyze(self, oFile):
     for iLineNumber, oLine in enumerate(oFile.lines):
         if oLine.insideConcurrent:
             if oLine.isConcurrentBegin and oLine.isEndConcurrent:
                 continue
             if oLine.isConcurrentBegin:
                 iAlignmentColumn = oLine.line.find('<') + 3
             else:
                 check.multiline_alignment(self, iAlignmentColumn, oLine, iLineNumber)
Ejemplo n.º 5
0
 def analyze(self, oFile):
     for iLineNumber, oLine in enumerate(oFile.lines):
         if oLine.isSequential and oLine.isSequentialEnd:
             continue
         if oLine.isSequential:
             iAlignmentColumn = oLine.line.find('<=') + len('<= ')
         if oLine.insideSequential and not oLine.isComment and not oLine.isSequential:
             check.multiline_alignment(self, iAlignmentColumn, oLine,
                                       iLineNumber)
Ejemplo n.º 6
0
 def analyze(self, oFile):
     for iLineNumber, oLine in enumerate(oFile.lines):
         if oLine.isVariableAssignment and oLine.isVariableAssignmentEnd:
             continue
         if oLine.isVariableAssignment:
             iAlignmentColumn = oLine.line.find(':=') + len(':= ')
             continue
         if oLine.insideVariableAssignment and not oLine.isComment:
             check.multiline_alignment(self, iAlignmentColumn, oLine,
                                       iLineNumber)
Ejemplo n.º 7
0
 def analyze(self, oFile):
     for iLineNumber, oLine in enumerate(oFile.lines):
         if oLine.isCaseWhenKeyword and oLine.isCaseWhenEnd:
             continue
         if oLine.isCaseWhenKeyword:
             iAlignmentColumn = (oLine.indentLevel *
                                 self.indentSize) + len('when ')
             continue
         if oLine.insideCaseWhen:
             check.multiline_alignment(self, iAlignmentColumn, oLine,
                                       iLineNumber)
Ejemplo n.º 8
0
 def analyze(self, oFile):
     for iLineNumber, oLine in enumerate(oFile.lines):
         if oLine.isSensitivityListBegin and oLine.isSensitivityListEnd:
             continue
         if oLine.insideSensitivityList:
             if oLine.isSensitivityListBegin:
                 iAlignmentColumn = oLine.line.find('(')
             elif oLine.isSensitivityListEnd and re.match(
                     '^\s*\)', oLine.line):
                 check.multiline_alignment(self, iAlignmentColumn, oLine,
                                           iLineNumber)
Ejemplo n.º 9
0
 def analyze(self, oFile):
     fCheckAlignment = False
     for iLineNumber, oLine in enumerate(oFile.lines):
         if oLine.isIfKeyword and oLine.isThenKeyword:
             continue
         if oLine.isElseIfKeyword and oLine.isThenKeyword:
             continue
         if oLine.isIfKeyword:
             if re.match('^\s+if\s\(', oLine.lineLower):
                 iAlignmentColumn = oLine.lineLower.find('(')
                 fCheckAlignment = True
             continue  # pragma: no cover
         if oLine.isElseIfKeyword:
             if re.match('^\s+elsif\s\(', oLine.lineLower):
                 iAlignmentColumn = oLine.lineLower.find('(')
                 fCheckAlignment = True
             continue  # pragma: no cover
         if oLine.insideIf and fCheckAlignment:
             check.multiline_alignment(self, iAlignmentColumn + 1, oLine,
                                       iLineNumber)
         if oLine.isThenKeyword:
             fCheckAlignment = False