Add OpConstant

This commit is contained in:
ReinUsesLisp
2018-08-27 00:29:40 -03:00
parent f68dbb20fc
commit 48cbe695f0
8 changed files with 162 additions and 20 deletions

View File

@@ -13,7 +13,7 @@ namespace Sirit {
Op::Op(spv::Op opcode_, u32 id_, const Op* result_type_)
: opcode(opcode_), id(id_), result_type(result_type_) {
operand_type = OperandType::Ref;
operand_type = OperandType::Op;
}
Op::~Op() = default;
@@ -69,7 +69,7 @@ void Op::Add(const Operand* operand) {
}
void Op::Add(u32 integer) {
Add(new LiteralInteger(integer));
Add(new LiteralNumber(integer));
}
void Op::Add(const std::string& string) {