Skip to content
  • Friedrich W. H. Kossebau's avatar
    Turn some sequences of x += ... statements (with x a QString) into a long... · 237fd7be
    Friedrich W. H. Kossebau authored
    Turn some sequences of x += ... statements (with x a QString) into a long chain of additions (for QStringBuilder)
    
    The power of QStringBuilder only sets in if more than two strings are concatenated
    before picking up the result as QString again (e.g. when assigning to a QString variable).
    There are some code parts where a lot of concatenating is done, but not in one expression,
    instead assigning the intermediate result to a QString var again and again, thus preventing
    the advantage of QStringBuilder.
    
    There are also a few places in the code where literal strings are concatenated using "+",
    instead of having the compiler concatenate them already.
    
    Patch optimizes the code in those two cases: by removing "+" between literal string and
    turning sequences of += into a chain of +
    
    REVIEW: 111595
    
    thanks boud for review
    237fd7be