diff options
Diffstat (limited to 'src/de/fernflower/modules/decompiler/ExprentStack.java')
-rw-r--r-- | src/de/fernflower/modules/decompiler/ExprentStack.java | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/src/de/fernflower/modules/decompiler/ExprentStack.java b/src/de/fernflower/modules/decompiler/ExprentStack.java new file mode 100644 index 0000000..6e76683 --- /dev/null +++ b/src/de/fernflower/modules/decompiler/ExprentStack.java @@ -0,0 +1,46 @@ +/* + * Fernflower - The Analytical Java Decompiler + * http://www.reversed-java.com + * + * (C) 2008 - 2010, Stiver + * + * This software is NEITHER public domain NOR free software + * as per GNU License. See license.txt for more details. + * + * This software is distributed WITHOUT ANY WARRANTY; without + * even the implied warranty of MERCHANTABILITY or FITNESS FOR + * A PARTICULAR PURPOSE. + */ + +package de.fernflower.modules.decompiler; + +import de.fernflower.modules.decompiler.exps.Exprent; +import de.fernflower.util.ListStack; + +public class ExprentStack extends ListStack<Exprent> { + + public ExprentStack() {} + + public ExprentStack(ListStack<Exprent> list) { + super(list); + pointer = list.getPointer(); + } + + public Exprent push(Exprent item) { + super.push(item); + + return item; + } + + public Exprent pop() { + + Exprent o = this.remove(--pointer); + + return o; + } + + public ExprentStack clone() { + return new ExprentStack(this); + } + +} |