Skip to content

Commit f7bc18f

Browse files
committed
Fix compatibility with catch v2
Catch v2 changed the `run(...)` signature to take a `char *argv[]`, arguing partly that technically a `char *argv[]` type is the correct `main()` signature rather than `const char *argv[]`. Dropping the `const` here doesn't appear to cause any problems with catch v1 (tested against both the cmake-downloaded 1.9.3 and Debian's 1.12.1 package) so we can follow suit.
1 parent cbd16a8 commit f7bc18f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tests/test_embed/catch.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414

1515
namespace py = pybind11;
1616

17-
int main(int argc, const char *argv[]) {
17+
int main(int argc, char *argv[]) {
1818
py::scoped_interpreter guard{};
1919
auto result = Catch::Session().run(argc, argv);
2020

0 commit comments

Comments
 (0)