Changeset 4ec9513 for src/AST/Expr.hpp


Ignore:
Timestamp:
Apr 13, 2022, 2:55:51 PM (2 years ago)
Author:
Andrew Beach <ajbeach@…>
Branches:
ADT, ast-experimental, enum, master, pthread-emulation, qualifiedEnum
Children:
365c8dcb
Parents:
6b06abe
Message:

Converted validate C, including adding DimensionExpr? to the new ast.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/AST/Expr.hpp

    r6b06abe r4ec9513  
    604604};
    605605
     606class DimensionExpr final : public Expr {
     607public:
     608        std::string name;
     609
     610        DimensionExpr( const CodeLocation & loc, std::string name )
     611        : Expr( loc ), name( name ) {}
     612
     613        const Expr * accept( Visitor & v ) const override { return v.visit( this ); }
     614private:
     615        DimensionExpr * clone() const override { return new DimensionExpr{ *this }; }
     616        MUTATE_FRIEND
     617};
     618
    606619/// A GCC "asm constraint operand" used in an asm statement, e.g. `[output] "=f" (result)`.
    607620/// https://gcc.gnu.org/onlinedocs/gcc-4.7.1/gcc/Machine-Constraints.html#Machine-Constraints
Note: See TracChangeset for help on using the changeset viewer.