[BACK]Return to mklines.go CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / pkgsrc / pkgtools / pkglint / files

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /pkgsrc/pkgtools/pkglint/files/Attic/mklines.go between version 1.64 and 1.65

version 1.64, 2019/12/08 22:03:38 version 1.65, 2019/12/13 01:39:23
Line 103  func (mklines *MkLines) collectRationale
Line 103  func (mklines *MkLines) collectRationale
                 return mkline.IsComment() && !mkline.IsCommentedVarassign()                  return mkline.IsComment() && !mkline.IsCommentedVarassign()
         }          }
   
         rationale := false          var rat strings.Builder
         for _, mkline := range mklines.mklines {          for _, mkline := range mklines.mklines {
                 rationale = rationale || isRealComment(mkline) && isUseful(mkline)                  if isRealComment(mkline) && isUseful(mkline) {
                 mkline.splitResult.hasRationale = rationale || isUseful(mkline)                          rat.WriteString(mkline.Comment())
                 rationale = rationale && !mkline.IsEmpty()                          rat.WriteString("\n")
                   }
   
                   var lineRat strings.Builder
                   lineRat.WriteString(rat.String())
                   if isUseful(mkline) {
                           lineRat.WriteString(mkline.Comment())
                           lineRat.WriteString("\n")
                   }
   
                   mkline.splitResult.rationale = lineRat.String()
                   if mkline.IsEmpty() {
                           rat.Reset()
                   }
         }          }
 }  }
   

Legend:
Removed from v.1.64  
changed lines
  Added in v.1.65

CVSweb <webmaster@jp.NetBSD.org>