On Thu, Dec 15, 2016 at 07:14:15AM -0500, Nathan Sidwell wrote: > On 12/15/2016 03:34 AM, Jakub Jelinek wrote: > > Hi! > > > > I'd like to ping the > > > > http://gcc.gnu.org/ml/gcc-patches/2016-12/msg00698.html > > P0490R0 GB 20: decomposition declaration should commit to tuple > > interpretation early > > + if (inst == error_mark_node) > + return NULL_TREE; > > This check is unneeded, because complete_type DTRT with error_mark_node > > + inst = complete_type (inst); > + if (!COMPLETE_TYPE_P (inst)) > + return NULL_TREE;
I don't think so. complete_type (error_mark_node) returns error_mark_node, and COMPLETE_TYPE_P (error_mark_node) is invalid (should fail TYPE_CHECK in checking compiler). I can write it as inst = complete_type (inst); if (inst == error_mark_node || !COMPLETE_TYPE_P (inst)) return NULL_TREE; Jakub