qlalr: fix build in C++17
std::unary_function and std::binary_function are gone. Remove their uses. Change-Id: I5d0ee9389a794d80983efffd152c96f0f2149b40 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
This commit is contained in:
parent
2c93ff91be
commit
85278a6970
@ -37,7 +37,7 @@
|
||||
|
||||
#define QLALR_NO_CHECK_SORTED_TABLE
|
||||
|
||||
struct _Fit: public std::binary_function<int, int, bool>
|
||||
struct _Fit
|
||||
{
|
||||
inline bool operator () (int a, int b) const
|
||||
{
|
||||
@ -45,7 +45,7 @@ struct _Fit: public std::binary_function<int, int, bool>
|
||||
}
|
||||
};
|
||||
|
||||
struct _PerfectMatch: public std::binary_function<int, int, bool>
|
||||
struct _PerfectMatch
|
||||
{
|
||||
inline bool operator () (int a, int b) const
|
||||
{ return a == b; }
|
||||
@ -135,7 +135,7 @@ private:
|
||||
const_iterator _M_endNonZeros;
|
||||
};
|
||||
|
||||
struct _SortUncompressedRow: public std::binary_function<UncompressedRow, UncompressedRow, bool>
|
||||
struct _SortUncompressedRow
|
||||
{
|
||||
inline bool operator () (const UncompressedRow &a, const UncompressedRow &b) const
|
||||
{ return a.count (0) > b.count (0); }
|
||||
|
@ -242,8 +242,9 @@ void Grammar::buildExtendedGrammar ()
|
||||
non_terminals.insert (accept_symbol);
|
||||
}
|
||||
|
||||
struct Nullable: public std::unary_function<Name, bool>
|
||||
struct Nullable
|
||||
{
|
||||
typedef Name argument_type;
|
||||
Automaton *_M_automaton;
|
||||
|
||||
Nullable (Automaton *aut):
|
||||
|
Loading…
x
Reference in New Issue
Block a user