37 : name_{std::move(
name)}, value_{value}, has_explicit_value_{false}, position_{
position}
59 [[nodiscard]]
const std::string &
name()
const
81 return has_explicit_value_;
97 bool has_explicit_value_;
Represents a single member (constant) within a C enum declaration.
EnumMember(std::string name, std::int64_t value, SourcePosition position)
Constructs an EnumMember with an implicit (counter-based) value.
std::int64_t int_value() const
Returns the resolved integer value.
const SourcePosition & position() const
Returns the source position of the member.
const std::string & name() const
Returns the member name.
bool has_explicit_value() const
Checks if this member had an explicit value assignment.
EnumMember(std::string name, std::int64_t value, bool has_explicit_value, SourcePosition position)
Constructs an EnumMember with explicit value flag.
Represents a position within source content.