Make example of delegating methods with parameterless expressions more explicit.

This commit is contained in:
Benjamin Marks 2022-10-31 10:42:33 -07:00 committed by GitHub
parent c29315dda4
commit 108091feaf
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -540,8 +540,8 @@ arguments:
```cpp
class MockTurtleFactory : public TurtleFactory {
public:
Turtle* MakeTurtle(int length, int weight) override { ... }
Turtle* MakeTurtle(int length, int weight, int speed) override { ... }
Turtle* MakeTurtle(int length, int weight) override { return DoMakeTurtle(); }
Turtle* MakeTurtle(int length, int weight, int speed) override { return DoMakeTurtle(); }
// the above methods delegate to this one:
MOCK_METHOD(Turtle*, DoMakeTurtle, ());