-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: Fix clang-tidy warnings for the rest of files directly unde…
…r `src/clp_ffi_py`; Use `std::string_view` for static error message strings. (#102)
- Loading branch information
1 parent
b0df0dc
commit b1cbedb
Showing
11 changed files
with
111 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,18 @@ | ||
#ifndef CLP_FFI_PY_ERROR_MESSAGES | ||
#define CLP_FFI_PY_ERROR_MESSAGES | ||
|
||
#include <string_view> | ||
|
||
namespace clp_ffi_py { | ||
constexpr char const* const cOutofMemoryError = "Failed to allocate memory."; | ||
constexpr char const* const cPyTypeError = "Wrong Python Type received."; | ||
constexpr char const* const cSetstateInputError | ||
= "Python dictionary is expected to be the input of __setstate__ method."; | ||
constexpr char const* const cSetstateKeyErrorTemplate = "\"%s\" not found in the state dictionary."; | ||
constexpr char const* const cTimezoneObjectNotInitialzed | ||
= "Timezone (tzinfo) object is not yet initialized."; | ||
constexpr std::string_view cOutOfMemoryError{"Failed to allocate memory."}; | ||
constexpr std::string_view cPyTypeError{"Wrong Python Type received."}; | ||
constexpr std::string_view cSetstateInputError{ | ||
"Python dictionary is expected to be the input of __setstate__ method." | ||
}; | ||
constexpr std::string_view cSetstateKeyErrorTemplate{"\"%s\" not found in the state dictionary."}; | ||
constexpr std::string_view cTimezoneObjectNotInitialized{ | ||
"Timezone (tzinfo) object is not yet initialized." | ||
}; | ||
} // namespace clp_ffi_py | ||
|
||
#endif // CLP_FFI_PY_ERROR_MESSAGES |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.