On 08/30/18 06:34, Jason Merrill wrote: > On 08/24/2018 03:52 PM, Bernd Edlinger wrote: >> this updated patch fixes one regression with current trunk due >> to a new test case. Sorry for the confusion. >> >> The change to the previous version is: >> 1) the check to avoid folding on empty char arrays is restored. >> 2) A null-termination character is added except when the string is full >> length. > >> - && TYPE_STRING_FLAG (TREE_TYPE (valtype))) > >> + tree typ1 = TYPE_MAIN_VARIANT (TREE_TYPE (type)); >> + if (typ1 == char_type_node >> + || typ1 == signed_char_type_node >> + || typ1 == unsigned_char_type_node) > > > Why stop using TYPE_STRING_FLAG? >
No longer sure, I will try it with TYPE_STRING_FLAG. Bernd.