mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-01-04 15:50:10 +01:00
26 lines
647 B
C++
26 lines
647 B
C++
#pragma once
|
|
|
|
#include "PreincNodeIterable.hpp"
|
|
#include "RegionLike.hpp"
|
|
|
|
namespace shader::ir {
|
|
struct RegionLikeImpl {
|
|
Instruction first = nullptr;
|
|
Instruction last = nullptr;
|
|
|
|
virtual ~RegionLikeImpl() = default;
|
|
|
|
template <typename T = Instruction> auto children() const {
|
|
return PreincNodeIterable<T>{first, nullptr};
|
|
}
|
|
|
|
template <typename T = Instruction> auto revChildren() const {
|
|
return RevPreincNodeIterable<T>{last, nullptr};
|
|
}
|
|
|
|
virtual void insertAfter(Instruction point, Instruction node);
|
|
virtual void prependChild(Instruction node);
|
|
virtual void addChild(Instruction node);
|
|
};
|
|
} // namespace shader::ir
|