| Summary: | No error for destructor name mismatch | ||
|---|---|---|---|
| Product: | [Tools] CDT | Reporter: | Nathan Ridge <zeratul976> |
| Component: | cdt-parser | Assignee: | Markus Schorn <mschorn.eclipse> |
| Status: | RESOLVED FIXED | QA Contact: | Markus Schorn <mschorn.eclipse> |
| Severity: | normal | ||
| Priority: | P3 | CC: | cdtdoug |
| Version: | 8.1.0 | ||
| Target Milestone: | 8.1.0 | ||
| Hardware: | All | ||
| OS: | All | ||
| Whiteboard: | |||
I agree. Added testcase and fix. |
CDT gives an error when the name of a constructor does not match the name of the class: struct A { B(); // syntax error }; However, it does not give a similar error for a destructor: struct A { ~B(); // no error }; For consistency, I think CDT should give an error in both cases.