Ignore:
Timestamp:
Apr 18, 2024, 5:19:17 PM (3 months ago)
Author:
Andrew Beach <ajbeach@…>
Branches:
master
Children:
38093ae
Parents:
60c5b6d
Message:

Moved ast::BasicType::Kind to ast::BasicKind? in its own hearder. This is more consistent with other utility enums (although we still use this as a enum class) and reduces what some files need to include. Also did a upgrade in a comment with MAX_INTEGER_TYPE, it is now part of the enum.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/Common/ResolvProtoDump.cpp

    r60c5b6d r7a780ad  
    229229        void previsit( const ast::EnumInstType * ) {
    230230                // TODO: Add the meaningful text representation of typed enum
    231                 ss << (int)ast::BasicType::SignedInt;
     231                ss << (int)ast::BasicKind::SignedInt;
    232232        }
    233233
     
    255255        // TODO: Support 0 and 1 with their type names and conversions.
    256256        void previsit( const ast::ZeroType * ) {
    257                 ss << (int)ast::BasicType::SignedInt;
     257                ss << (int)ast::BasicKind::SignedInt;
    258258        }
    259259
    260260        void previsit( const ast::OneType * ) {
    261                 ss << (int)ast::BasicType::SignedInt;
     261                ss << (int)ast::BasicKind::SignedInt;
    262262        }
    263263
     
    366366        // TODO: Extra expression to resolve argument.
    367367        void previsit( const ast::SizeofExpr * ) {
    368                 ss << (int)ast::BasicType::LongUnsignedInt;
     368                ss << (int)ast::BasicKind::LongUnsignedInt;
    369369                visit_children = false;
    370370        }
    371371        void previsit( const ast::AlignofExpr * ) {
    372                 ss << (int)ast::BasicType::LongUnsignedInt;
     372                ss << (int)ast::BasicKind::LongUnsignedInt;
    373373                visit_children = false;
    374374        }
    375375        void previsit( const ast::UntypedOffsetofExpr * ) {
    376                 ss << (int)ast::BasicType::LongUnsignedInt;
     376                ss << (int)ast::BasicKind::LongUnsignedInt;
    377377                visit_children = false;
    378378        }
     
    753753                // &? Address of operator.
    754754                out << "#$ptr<T> $addr T" << std::endl;
    755                 const int intId = (int)ast::BasicType::SignedInt;
     755                const int intId = (int)ast::BasicKind::SignedInt;
    756756                // ?&&? ?||? ?: Logical operators.
    757757                out << intId << " $and " << intId << ' ' << intId << std::endl;
Note: See TracChangeset for help on using the changeset viewer.