[cfe-dev] Q. on recent fixit changes

Robinson, Paul Paul_Robinson at playstation.sony.com
Mon Dec 15 15:51:41 PST 2014


I've seen a difference in whether some fixits are produced, recently
(i.e. sometime between r222093 and r222640).  Mainly I want to know
whether it's intentional, given the recent changes to fixit handling
(which I didn't really pay much attention to).  If it's intentional,
cool, I'll just update my tests; but if it isn't, then I can file a
bug so somebody can look into it.

Given the following source:

namespace std {
  void *junk();
};
int main() {
  delete junk;
  return 0;
}

This used to get an error with a fixit:

try.cpp:8:10: error: use of undeclared identifier 'junk'; did you mean
      'std::junk'?
  delete junk;
         ^~~~
         std::junk
try.cpp:4:9: note: 'std::junk' declared here
  void *junk();
        ^
try.cpp:8:3: error: cannot delete expression of type 'void *()'
  delete junk;
  ^      ~~~~
2 errors generated.


Now it doesn't:

try.cpp:8:10: error: use of undeclared identifier 'junk'
  delete junk;
         ^
1 error generated.

Thanks,
--paulr





More information about the cfe-dev mailing list