Try to further fix compilation on GCC

This commit is contained in:
blankie 2023-04-10 21:24:11 +07:00
parent a1171e9431
commit ed7acd97cf
Signed by: blankie
GPG Key ID: CC15FC822C7F61F5
4 changed files with 8 additions and 8 deletions

View File

@ -27,8 +27,8 @@ std::string escape(const std::string& in) {
return out;
}
}; // namespace html
}; // namespace blankie
} // namespace html
} // namespace blankie
static inline const char* get_replacement(char c) {
switch (c) {

View File

@ -134,8 +134,8 @@ std::string normalize_path(const std::string& str) {
return res;
}
}; // namespace murl
}; // namespace blankie
} // namespace murl
} // namespace blankie
static void handle_segment(std::vector<std::string>& segments, const std::string& str, size_t offset, size_t length) {
if (length == 2 && str[offset] == '.' && str[offset + 1] == '.') {

View File

@ -48,8 +48,8 @@ std::string Element::serialize() const {
return out;
}
}; // namespace html
}; // namespace blankie
} // namespace html
} // namespace blankie
static inline bool is_autoclosing_tag(const char* tag) {
return !strncmp(tag, "link", 5) || !strncmp(tag, "meta", 5) || !strncmp(tag, "img", 4) || !strncmp(tag, "br", 3);

View File

@ -25,7 +25,7 @@ public:
this->_message = httplib::to_string(error);
}
const constexpr char* what() const noexcept {
inline const char* what() const noexcept {
return this->_message.c_str();
}
@ -37,7 +37,7 @@ class PixivException : public std::exception {
public:
PixivException(int status_, std::string message) : status(status_), _message(std::move(message)) {}
const constexpr char* what() const noexcept {
inline const char* what() const noexcept {
return this->_message.c_str();
}