Changeset bc07190 for src/AST/Decl.hpp
- Timestamp:
- Jun 29, 2024, 7:33:28 AM (10 months ago)
- Branches:
- master
- Children:
- 011c29e
- Parents:
- 62a38e7 (diff), 115ac1ce (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified src/AST/Decl.hpp ¶
r62a38e7 rbc07190 308 308 class EnumDecl final : public AggregateDecl { 309 309 public: 310 // is Typedindicated if the enum has a declaration like:310 // isCfa indicated if the enum has a declaration like: 311 311 // enum (type_optional) Name {...} 312 bool is Typed;313 // if is Typed == true && base.get() == nullptr, it is a "void" typeenum312 bool isCfa; 313 // if isCfa == true && base.get() == nullptr, it is a "opague" enum 314 314 ptr<Type> base; 315 315 enum class EnumHiding { Visible, Hide } hide; 316 316 std::vector< ast::ptr<ast::EnumInstType>> inlinedDecl; // child enums 317 317 318 EnumDecl( const CodeLocation& loc, const std::string& name, bool is Typed= false,318 EnumDecl( const CodeLocation& loc, const std::string& name, bool isCfa = false, 319 319 std::vector<ptr<Attribute>>&& attrs = {}, Linkage::Spec linkage = Linkage::Cforall, 320 320 Type const * base = nullptr, EnumHiding hide = EnumHiding::Hide, 321 321 std::unordered_map< std::string, long long > enumValues = std::unordered_map< std::string, long long >() ) 322 : AggregateDecl( loc, name, std::move(attrs), linkage ), is Typed(isTyped), base(base), hide(hide), enumValues(enumValues) {}322 : AggregateDecl( loc, name, std::move(attrs), linkage ), isCfa(isCfa), base(base), hide(hide), enumValues(enumValues) {} 323 323 324 324 /// gets the integer value for this enumerator, returning true iff value found … … 336 336 337 337 bool isSubTypeOf(const ast::EnumDecl *) const; 338 bool isTyped() const; 339 bool isOpague() const; 338 340 private: 339 341 EnumDecl * clone() const override { return new EnumDecl{ *this }; }
Note: See TracChangeset
for help on using the changeset viewer.