Cleaned up various TODO comments

git-svn-id: https://smali.googlecode.com/svn/trunk@37 55b6fa8a-2a1e-11de-a435-ffa8d773f76a
This commit is contained in:
JesusFreke@JesusFreke.com 2009-05-11 00:44:19 +00:00
parent 8a116bba98
commit edb11ae910
5 changed files with 0 additions and 17 deletions

View File

@ -103,11 +103,6 @@ public class CodeItem extends OffsettedItem<CodeItem> {
}; };
} }
//TODO: take out
public void writeTo(Output out) {
super.writeTo(out);
}
protected int getAlignment() { protected int getAlignment() {
return 4; return 4;
} }

View File

@ -53,9 +53,6 @@ public abstract class Item<T extends Item> {
public int place(int index, int offset) { public int place(int index, int offset) {
offset = alignOffset(offset); offset = alignOffset(offset);
//TODO: take out
System.out.println("Placing item type " + getItemType().getTypeName() + " at offset " + ((Integer)offset).toString());
this.offset = offset; this.offset = offset;
Field[] fields = getFields(); Field[] fields = getFields();
@ -75,9 +72,6 @@ public abstract class Item<T extends Item> {
public void writeTo(Output out) { public void writeTo(Output out) {
out.alignTo(getAlignment()); out.alignTo(getAlignment());
//TODO: take out
System.out.println("Writing item type " + getItemType().getTypeName() + " at offset " + ((Integer)out.getCursor()).toString());
if (out.getCursor() != offset) { if (out.getCursor() != offset) {
throw new RuntimeException("Item is being written somewhere other than where it was placed"); throw new RuntimeException("Item is being written somewhere other than where it was placed");
} }

View File

@ -55,9 +55,6 @@ public class OffsettedItemReference<T extends OffsettedItem<T>> extends
throw new RuntimeException("Trying to write reference to an item that hasn't been placed."); throw new RuntimeException("Trying to write reference to an item that hasn't been placed.");
} }
/*if (out.getCursor() != underlyingField.getCachedValue()) {
throw new RuntimeException("Trying to write a reference in a difference location from where it was placed");
}*/
//TODO: this is a hack to force it to reload the correct offset value //TODO: this is a hack to force it to reload the correct offset value
if (item == null) { if (item == null) {
underlyingField.cacheValue(0); underlyingField.cacheValue(0);

View File

@ -55,7 +55,6 @@ public class SparseSwitchData
bytes = new byte[targets.length * 8 + 4]; bytes = new byte[targets.length * 8 + 4];
int position = 8; int position = 8;
//TODO: should we throw an error if there are no switch elements?
if (targets.length > 0) { if (targets.length > 0) {
int key = keys[0]; int key = keys[0];
bytes[4] = (byte)key; bytes[4] = (byte)key;

View File

@ -32,8 +32,6 @@ import org.JesusFreke.dexlib.*;
import org.JesusFreke.dexlib.util.Input; import org.JesusFreke.dexlib.util.Input;
import org.JesusFreke.dexlib.util.Output; import org.JesusFreke.dexlib.util.Output;
//TODO: need to implement the "special" bytecode types, for switches etc.
public final class Instruction implements Field<Instruction> { public final class Instruction implements Field<Instruction> {
private DexFile dexFile; private DexFile dexFile;
private byte[] bytes; private byte[] bytes;