Hi, this is about suboptimal error messages for the kind of code distilled by Jonathan in Comment #2: class Rule { Rule(int e); }; const Rule::Rule(int e) { } that is, an error message of the type "error: prototype for ‘Rule::Rule()’ does not match any in class ‘Rule’" and no mention of the fact that the const qualifier doesn't make sense. In fact, however, in grokdeclarator we already emit sensible error messages for operators, thus the patch below mostly boils down to unifying the logic inside check_special_function_return_type. There is also a new smallest_type_quals_location helper function which computes an optimal location for the error message in case of multiple qualifiers, that is corresponding to the leftmost one. Tested x86_64-linux. Thanks, Paolo. ////////////////////////