On fpc_*_concat_multi involving only one nonempty string, return it directly if possible.
Patch: [multi.patch](/uploads/f5b50f8c6eb6fe0cc631234189c8a07e/multi.patch). USE CASE: ```pascal displayedName := IfThen(stolen, '!', '') + 'pile of bones' + IfThen(stolen, '!', ''); ``` This also removes several redundant actions, either as a no-brainer or relying on that `Move`ing zero bytes is a fast enough no-op. In particular, why would you _purposely move null terminators_ (`Size + 1` characters instead of `Size`). This can change the behavior slightly: if the only nonempty input string had a placeholder codepage and the requested codepage was “semantically equivalent”, result (remains the new reference to the same string and therefore) retains the placeholder. I think this is _more_ consistent, as the following code: ```pascal {$mode objfpc} {$longstrings on} var a, b, empty: string; begin DefaultSystemCodePage := 12345; empty := ''; a := empty + 'A' + empty; writeln('concat_multi codepage: ', StringCodePage(a)); b := empty + 'B'; b := b + empty; writeln('concat, concat codepage: ', StringCodePage(b)); end. ``` outputs ``` concat_multi codepage: 12345 concat, concat codepage: 0 ``` before the patch, and ``` concat_multi codepage: 0 concat, concat codepage: 0 ``` after the patch.
issue