Skip to content

Commit c8a5993

Browse files
author
Hana Dusíková
committed
avoid -Wshadow warning in clang
1 parent 871a29c commit c8a5993

File tree

3 files changed

+12
-12
lines changed

3 files changed

+12
-12
lines changed

include/ctll/parser.hpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -130,15 +130,15 @@ template <typename Grammar, const auto & input, typename ActionSelector = empty_
130130
// and push string without the character (quick LL(1))
131131
template <size_t Pos, auto V, typename... Content, typename Stack, typename Subject>
132132
static constexpr auto move(push<term<V>, Content...>, term<V>, Stack stack, Subject) noexcept {
133-
constexpr auto _input = input;
134-
return typename parser<Grammar, _input, ActionSelector, IgnoreUnknownActions>::template results<Pos+1, decltype(push_front(list<Content...>(), stack)), Subject, decision::undecided>();
133+
constexpr auto local_input = input;
134+
return typename parser<Grammar, local_input, ActionSelector, IgnoreUnknownActions>::template results<Pos+1, decltype(push_front(list<Content...>(), stack)), Subject, decision::undecided>();
135135
}
136136
// if rule is string with any character at the beginning (compatible with current term<T>) => move to next character
137137
// and push string without the character (quick LL(1))
138138
template <size_t Pos, auto V, typename... Content, auto T, typename Stack, typename Subject>
139139
static constexpr auto move(push<anything, Content...>, term<T>, Stack stack, Subject) noexcept {
140-
constexpr auto _input = input;
141-
return typename parser<Grammar, _input, ActionSelector, IgnoreUnknownActions>::template results<Pos+1, decltype(push_front(list<Content...>(), stack)), Subject, decision::undecided>();
140+
constexpr auto local_input = input;
141+
return typename parser<Grammar, local_input, ActionSelector, IgnoreUnknownActions>::template results<Pos+1, decltype(push_front(list<Content...>(), stack)), Subject, decision::undecided>();
142142
}
143143
// decide if we need to take action or move
144144
template <size_t Pos, typename Stack, typename Subject> static constexpr auto decide(Stack previous_stack, Subject previous_subject) noexcept {

single-header/ctre-unicode.hpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -842,15 +842,15 @@ template <typename Grammar, const auto & input, typename ActionSelector = empty_
842842
// and push string without the character (quick LL(1))
843843
template <size_t Pos, auto V, typename... Content, typename Stack, typename Subject>
844844
static constexpr auto move(push<term<V>, Content...>, term<V>, Stack stack, Subject) noexcept {
845-
constexpr auto _input = input;
846-
return typename parser<Grammar, _input, ActionSelector, IgnoreUnknownActions>::template results<Pos+1, decltype(push_front(list<Content...>(), stack)), Subject, decision::undecided>();
845+
constexpr auto local_input = input;
846+
return typename parser<Grammar, local_input, ActionSelector, IgnoreUnknownActions>::template results<Pos+1, decltype(push_front(list<Content...>(), stack)), Subject, decision::undecided>();
847847
}
848848
// if rule is string with any character at the beginning (compatible with current term<T>) => move to next character
849849
// and push string without the character (quick LL(1))
850850
template <size_t Pos, auto V, typename... Content, auto T, typename Stack, typename Subject>
851851
static constexpr auto move(push<anything, Content...>, term<T>, Stack stack, Subject) noexcept {
852-
constexpr auto _input = input;
853-
return typename parser<Grammar, _input, ActionSelector, IgnoreUnknownActions>::template results<Pos+1, decltype(push_front(list<Content...>(), stack)), Subject, decision::undecided>();
852+
constexpr auto local_input = input;
853+
return typename parser<Grammar, local_input, ActionSelector, IgnoreUnknownActions>::template results<Pos+1, decltype(push_front(list<Content...>(), stack)), Subject, decision::undecided>();
854854
}
855855
// decide if we need to take action or move
856856
template <size_t Pos, typename Stack, typename Subject> static constexpr auto decide(Stack previous_stack, Subject previous_subject) noexcept {

single-header/ctre.hpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -839,15 +839,15 @@ template <typename Grammar, const auto & input, typename ActionSelector = empty_
839839
// and push string without the character (quick LL(1))
840840
template <size_t Pos, auto V, typename... Content, typename Stack, typename Subject>
841841
static constexpr auto move(push<term<V>, Content...>, term<V>, Stack stack, Subject) noexcept {
842-
constexpr auto _input = input;
843-
return typename parser<Grammar, _input, ActionSelector, IgnoreUnknownActions>::template results<Pos+1, decltype(push_front(list<Content...>(), stack)), Subject, decision::undecided>();
842+
constexpr auto local_input = input;
843+
return typename parser<Grammar, local_input, ActionSelector, IgnoreUnknownActions>::template results<Pos+1, decltype(push_front(list<Content...>(), stack)), Subject, decision::undecided>();
844844
}
845845
// if rule is string with any character at the beginning (compatible with current term<T>) => move to next character
846846
// and push string without the character (quick LL(1))
847847
template <size_t Pos, auto V, typename... Content, auto T, typename Stack, typename Subject>
848848
static constexpr auto move(push<anything, Content...>, term<T>, Stack stack, Subject) noexcept {
849-
constexpr auto _input = input;
850-
return typename parser<Grammar, _input, ActionSelector, IgnoreUnknownActions>::template results<Pos+1, decltype(push_front(list<Content...>(), stack)), Subject, decision::undecided>();
849+
constexpr auto local_input = input;
850+
return typename parser<Grammar, local_input, ActionSelector, IgnoreUnknownActions>::template results<Pos+1, decltype(push_front(list<Content...>(), stack)), Subject, decision::undecided>();
851851
}
852852
// decide if we need to take action or move
853853
template <size_t Pos, typename Stack, typename Subject> static constexpr auto decide(Stack previous_stack, Subject previous_subject) noexcept {

0 commit comments

Comments
 (0)