For the following code: modernize-use-override generates a replacement with incorrect location.
struct IntPair { int first, second; }; struct A { virtual void il(IntPair); }; struct B : A { void il(IntPair p = {1, (2 + 3)}) {}; // Generated Fixit: void il(IntPair p = override {1, (2 + 3)}) {}; // Should be: void il(IntPair p = {1, (2 + 3)}) override {}; };
This fixes that and adds a unit test.