package st.gravel.support.compiler.jvm;
/*
This file is automatically generated from typed smalltalk source. Do not edit by hand.
(C) AG5.com
*/
import java.math.BigInteger;
import st.gravel.support.jvm.NonLocalReturn;
import st.gravel.support.compiler.jvm.WhileLoop;
import st.gravel.support.compiler.jvm.WhileLoop.WhileLoop_Factory;
import st.gravel.support.compiler.jvm.JVMStack;
import st.gravel.support.compiler.jvm.JVMInstruction;
import st.gravel.support.compiler.jvm.Frame;
import st.gravel.support.compiler.jvm.JVMType;
public class WhileBooleanLoop extends WhileLoop implements Cloneable {
public static WhileBooleanLoop_Factory factory = new WhileBooleanLoop_Factory();
public static class WhileBooleanLoop_Factory extends WhileLoop_Factory {
public WhileBooleanLoop basicNew() {
WhileBooleanLoop newInstance = new WhileBooleanLoop();
newInstance.initialize();
return newInstance;
}
}
public WhileBooleanLoop copy() {
try {
WhileBooleanLoop _temp1 = (WhileBooleanLoop) this.clone();
_temp1.postCopy();
return _temp1;
} catch (CloneNotSupportedException e) {
throw new RuntimeException(e);
}
}
@Override
public JVMInstruction effectStack_(final JVMStack _aJVMStack) {
super.effectStack_(_aJVMStack);
st.gravel.support.jvm.ObjectExtensions.assert_(this, st.gravel.support.jvm.IntegerExtensions.equals_(_testFrame.endStack().size(), 1));
st.gravel.support.jvm.ObjectExtensions.assert_(this, _testFrame.endStack().peek().isBooleanType());
return this;
}
public WhileBooleanLoop_Factory factory() {
return factory;
}
@Override
public WhileBooleanLoop initializeTestFrame_doFrame_(final Frame _aFrame, final Frame _aFrame2) {
_testFrame = _aFrame;
_doFrame = _aFrame2;
this.initialize();
return this;
}
@Override
public WhileBooleanLoop printOn_(final StringBuilder _aStream) {
final String _title;
_title = this.factory().toString();
_aStream.append(st.gravel.support.jvm.CharacterExtensions.isVowel(_title.charAt(0)) ? "an " : "a ");
_aStream.append(_title);
_aStream.append('[');
this.sourceOn_(_aStream);
_aStream.append(']');
return this;
}
@Override
public WhileBooleanLoop sourceOn_(final StringBuilder _aStream) {
return this;
}
@Override
public WhileBooleanLoop withReturnType_(final JVMType _aType) {
if (st.gravel.support.jvm.ObjectExtensions.equals_(this.type(), _aType)) {
return WhileBooleanLoop.this;
}
throw new RuntimeException("niy");
}
}