I quite often use the trim() function when concatenating string together so that spacing can be controlled (used often for creation filenames for example) however I noticed that if the variable being trimmed is blank none of the strings following are added to the string. Is this expected?
character*20 :: var1,var2,var3
character*132 :: string
var1 = '250.0'
var2 = 'millimetres'
var3 = 'tagline'
string = trim(var1)//' '//trim(var2)//' '//trim(var3)
string would be '250.0 millimetres tagline'
var2 = ' '
string would be just '250.0'
where I would expect '250.0 tagline'
I've only noticed this recently so may have been introduced in one of the later XE compiler updates.