Browse Source

shader: Use a non-trivial dummy to construct ASL node union

pull/15/merge
ReinUsesLisp 5 years ago
committed by ameerj
parent
commit
776ab3ea12
  1. 7
      src/shader_recompiler/frontend/ir/abstract_syntax_list.h

7
src/shader_recompiler/frontend/ir/abstract_syntax_list.h

@ -13,6 +13,10 @@ namespace Shader::IR {
class Block;
struct AbstractSyntaxNode {
struct NonTrivialDummy {
NonTrivialDummy() {}
};
enum class Type {
Block,
If,
@ -25,7 +29,8 @@ struct AbstractSyntaxNode {
};
Type type{};
union {
Block* block{};
NonTrivialDummy dummy{};
Block* block;
struct {
U1 cond;
Block* body;

Loading…
Cancel
Save