51 return std::strong_ordering::equal;
78 template <
typename Base >
82template <
typename Base >
84 if constexpr ( std::is_integral_v < Base > ) {
86 }
else if constexpr ( std::is_same_v < Base, std::string > ) {
87 return std::string ( 1, WildcardSymbol::instance < char > ( ) );
88 }
else if constexpr ( std::is_same_v < Base, WildcardSymbol > ) {
90 }
else if constexpr ( std::is_same_v < Base, object::Object > ) {
92 }
else if constexpr ( std::is_same_v < Base, common::ranked_symbol < > > ) {
96 static_assert ( std::is_same_v < Base, Base >,
"Unsupported type of instance" );
Represents a wildcard used as representation of anything here in a string or a tree.
Definition: WildcardSymbol.h:35
friend ext::ostream & operator<<(ext::ostream &out, const WildcardSymbol &instance)
Definition: WildcardSymbol.cpp:16
static Base instance()
Factory for the symbol construction of the symbol based on given type.
Definition: WildcardSymbol.h:83
std::strong_ordering operator<=>(const WildcardSymbol &) const
Definition: WildcardSymbol.h:50
bool operator==(const WildcardSymbol &) const
Definition: WildcardSymbol.h:61
WildcardSymbol()
Creates a new instance of the symbol.
Definition: ranked_symbol.hpp:20
Definition: BarSymbol.cpp:12