package org.shedlang.compiler.patio.instructions; import org.shedlang.compiler.patio.operands.PatioLocalRef; import org.shedlang.compiler.patio.operands.PatioOperand; import org.shedlang.compiler.sources.Source; import java.util.List; /// If the condition is true, execute the instructions in the "true" body, /// otherwise execute the instructions in the "false" body. /// /// Each block must have the same number of results as destinations. Each result is /// assigned to the destination with the same index. public record PatioIf( List destinations, PatioOperand condition, PatioBlock trueBody, PatioBlock falseBody, Source source ) implements PatioInstruction { @Override public boolean isBlockTerminator() { return false; } }