Ignore:
Timestamp:
Nov 16, 2015, 10:01:04 PM (4 years ago)
Author:
nmedfort
Message:

First stage in making And/Or/Xor? statements n-ary statements.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • icGREP/icgrep-devel/icgrep/pablo/pe_xor.h

    r4797 r4873  
    99
    1010#include <pablo/pabloAST.h>
    11 #include <array>
    1211
    1312namespace pablo {
    1413
    15 class Xor : public Statement {
     14class Xor : public Variadic {
    1615    friend class PabloBlock;
    1716public:
     
    2221        return false;
    2322    }
    24     virtual ~Xor() {
    25     }
    26     PabloAST * getExpr1() const {
    27         return getOperand(0);
    28     }
    29     PabloAST * getExpr2() const {
    30         return getOperand(1);
    31     }
     23    virtual ~Xor() { }
    3224protected:
    3325    Xor(PabloAST * expr1, PabloAST * expr2, String * name)
    34     : Statement(ClassTypeId::Xor, {expr1, expr2}, name)
     26    : Variadic(ClassTypeId::Xor, {expr1, expr2}, name)
    3527    {
    36         assert (getNumOperands() == 2);
     28
    3729    }
    3830};
Note: See TracChangeset for help on using the changeset viewer.