This adds a new error for missing parentheses around lambdas in delete operators.
int main() { delete []() { return new int(); }(); }
This will result in:
test.cpp:2:3: error: '[]' after delete interpreted as 'delete[]' delete []() { return new int(); }(); ^~~~~~~~~ test.cpp:2:9: note: add parentheses around the lambda delete []() { return new int(); }(); ^ ( )