Skip to content

Commit ac19dd0

Browse files
author
Hana Dusíková
committed
add explenation why atom_characters are not combination with sets and ranges
1 parent 715364e commit ac19dd0

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

include/ctre/atoms_characters.hpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,8 @@ template <typename... Content> struct negate {
4545
}
4646
};
4747

48+
// I know word_chars and others can be expressed with set<> and range<>, but this makes the regex bad readable when debugging, please keep this in mind when touching this code in future :)
49+
4850
struct word_chars {
4951
template <typename CharT> CTRE_FORCE_INLINE static constexpr bool match_char(CharT value) noexcept {
5052
return (value >= 'A' && value <= 'Z') || (value >= 'a' && value <= 'z') || (value >= '0' && value <= '9') || (value == '_');

0 commit comments

Comments
 (0)