Handle clang-tidy warnings
- Dominant language
- CMake
- Stars
- 116
- Forks
- 18
- PR merge metrics
- No merged PRs in 30d
Description
Currently seeing:
```
/Users/dane/projects/hpp-skel/test/test.cpp:7:5: error: do not use inline assembler in safety-critical code [hicpp-no-assembler,-warnings-as-errors]
REQUIRE(HELLOWORLD_VERSION_STRING == std::string("1.0.0"));
^
/Users/dane/projects/hpp-skel/mason_packages/headers/catch/1.9.6/include/catch.hpp:11450:25: note: expanded from macro 'REQUIRE'
#define REQUIRE( expr ) INTERNAL_CATCH_TEST( "REQUIRE", Catch::ResultDisposition::Normal, expr )
^
/Users/dane/projects/hpp-skel/mason_packages/headers/catch/1.9.6/include/catch.hpp:2207:9: note: expanded from macro 'INTERNAL_CATCH_TEST'
INTERNAL_CATCH_REACT( __catchResult ) \
^
/Users/dane/projects/hpp-skel/mason_packages/headers/catch/1.9.6/include/catch.hpp:2191:44: note: expanded from macro 'INTERNAL_CATCH_REACT'
if( resultBuilder.shouldDebugBreak() ) CATCH_BREAK_INTO_DEBUGGER(); \
^
/Users/dane/projects/hpp-skel/mason_packages/headers/catch/1.9.6/include/catch.hpp:2133:75: note: expanded from macro 'CATCH_BREAK_INTO_DEBUGGER'
#define CATCH_BREAK_INTO_DEBUGGER() if( Catch::isDebuggerActive() ) { CATCH_TRAP(); }
^
/Users/dane/projects/hpp-skel/mason_packages/headers/catch/1.9.6/include/catch.hpp:2111:30: note: expanded from macro 'CATCH_TRAP'
#define CATCH_TRAP() __asm__("int $3\n" : : )
^
/Users/dane/projects/hpp-skel/test/test.cpp:13:5: error: do not use inline assembler in safety-critical code [hicpp-no-assembler,-warnings-as-errors]
REQUIRE(value == std::string("hello!"));
^
/Users/dane/projects/hpp-skel/mason_packages/headers/catch/1.9.6/include/catch.hpp:11450:25: note: expanded from macro 'REQUIRE'
#define REQUIRE( expr ) INTERNAL_CATCH_TEST( "REQUIRE", Catch::ResultDisposition::Normal, expr )
^
/Users/dane/projects/hpp-skel/mason_packages/headers/catch/1.9.6/include/catch.hpp:2207:9: note: expanded from macro 'INTERNAL_CATCH_TEST'
INTERNAL_CATCH_REACT( __catchResult ) \
^
/Users/dane/projects/hpp-skel/mason_packages/headers/catch/1.9.6/include/catch.hpp:2191:44: note: expanded from macro 'INTERNAL_CATCH_REACT'
if( resultBuilder.shouldDebugBreak() ) CATCH_BREAK_INTO_DEBUGGER(); \
^
/Users/dane/projects/hpp-skel/mason_packages/headers/catch/1.9.6/include/catch.hpp:2133:75: note: expanded from macro 'CATCH_BREAK_INTO_DEBUGGER'
#define CATCH_BREAK_INTO_DEBUGGER() if( Catch::isDebuggerActive() ) { CATCH_TRAP(); }
^
/Users/dane/projects/hpp-skel/mason_packages/headers/catch/1.9.6/include/catch.hpp:2111:30: note: expanded from macro 'CATCH_TRAP'
#define CATCH_TRAP() __asm__("int $3\n" : : )
^
/Users/dane/projects/hpp-skel/test/test.cpp:20:5: error: do not use inline assembler in safety-critical code [hicpp-no-assembler,-warnings-as-errors]
REQUIRE(result == std::string("Expensive work is finished"));
^
/Users/dane/projects/hpp-skel/mason_packages/headers/catch/1.9.6/include/catch.hpp:11450:25: note: expanded from macro 'REQUIRE'
#define REQUIRE( expr ) INTERNAL_CATCH_TEST( "REQUIRE", Catch::ResultDisposition::Normal, expr )
^
/Users/dane/projects/hpp-skel/mason_packages/headers/catch/1.9.6/include/catch.hpp:2207:9: note: expanded from macro 'INTERNAL_CATCH_TEST'
INTERNAL_CATCH_REACT( __catchResult ) \
^
/Users/dane/projects/hpp-skel/mason_packages/headers/catch/1.9.6/include/catch.hpp:2191:44: note: expanded from macro 'INTERNAL_CATCH_REACT'
if( resultBuilder.shouldDebugBreak() ) CATCH_BREAK_INTO_DEBUGGER(); \
^
/Users/dane/projects/hpp-skel/mason_packages/headers/catch/1.9.6/include/catch.hpp:2133:75: note: expanded from macro 'CATCH_BREAK_INTO_DEBUGGER'
#define CATCH_BREAK_INTO_DEBUGGER() if( Catch::isDebuggerActive() ) { CATCH_TRAP(); }
^
/Users/dane/projects/hpp-skel/mason_packages/headers/catch/1.9.6/include/catch.hpp:2111:30: note: expanded from macro 'CATCH_TRAP'
#define CATCH_TRAP() __asm__("int $3\n" : : )
^
```
Contributor guide
Research direction
Start with test/test.cpp and the expanded Catch header at mason_packages/headers/catch/1.9.6/include/catch.hpp, then reproduce the reported clang-tidy warnings. Done means the test checks no longer produce these inline-assembler warnings with warnings treated as errors.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- testing, tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100