Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix clang-tidy error with panels.cpp #37988

Merged
merged 1 commit into from
Feb 13, 2020

Conversation

Kilvoctu
Copy link
Contributor

@Kilvoctu Kilvoctu commented Feb 13, 2020

Summary

SUMMARY: Bugfixes "Fix clang-tidy error with panels.cpp"

Purpose of change

One of my merged PR #37973 has caused an error with Clang-tidy CMake build with Tiles and Sound (in panels.cpp at line 1471):
error: Prefer constructing 'point' from named constant 'point_east' rather than explicit integer arguments. [cata-use-named-point-constants,-warnings-as-errors]

Describe the solution

In panels.cpp, each similar line that does point construction for drawing panels is preceded by:
// NOLINTNEXTLINE(cata-use-named-point-constants)
I'm inserting this line into the trouble spot.

Describe alternatives you've considered

Going through panels.cpp and simplifying point construction for the 26 instances in which no lint has been declared for it, but I'm concerned that this may cause further issues.

Testing

None. Allowing the continuous integration thing to test it.

Additional context

This error was discovered when looking at the tests for #37981. Link

@ZhilkinSerg ZhilkinSerg added [C++] Changes (can be) made in C++. Previously named `Code` Code: Build Issues regarding different builds and build environments labels Feb 13, 2020
@ZhilkinSerg ZhilkinSerg merged commit 4eca2cd into CleverRaven:master Feb 13, 2020
@Kilvoctu Kilvoctu deleted the panel-test-fix branch February 13, 2020 07:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[C++] Changes (can be) made in C++. Previously named `Code` Code: Build Issues regarding different builds and build environments
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants