aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGreg Hysen <greg.hysen@gmail.com>2018-11-13 05:06:45 +0800
committerGreg Hysen <greg.hysen@gmail.com>2018-11-29 08:38:10 +0800
commit13d456fda1da19c8227acb2bf23106bcbdaf6f12 (patch)
tree7ab0f154a914a538cb322181745e5928312c6035
parenta9e3d489d60df1be4805f1c84f136eb127fef949 (diff)
downloaddexon-0x-contracts-13d456fda1da19c8227acb2bf23106bcbdaf6f12.tar
dexon-0x-contracts-13d456fda1da19c8227acb2bf23106bcbdaf6f12.tar.gz
dexon-0x-contracts-13d456fda1da19c8227acb2bf23106bcbdaf6f12.tar.bz2
dexon-0x-contracts-13d456fda1da19c8227acb2bf23106bcbdaf6f12.tar.lz
dexon-0x-contracts-13d456fda1da19c8227acb2bf23106bcbdaf6f12.tar.xz
dexon-0x-contracts-13d456fda1da19c8227acb2bf23106bcbdaf6f12.tar.zst
dexon-0x-contracts-13d456fda1da19c8227acb2bf23106bcbdaf6f12.zip
removed old code
-rw-r--r--packages/order-utils/test/abi/calldata.ts38
1 files changed, 0 insertions, 38 deletions
diff --git a/packages/order-utils/test/abi/calldata.ts b/packages/order-utils/test/abi/calldata.ts
index 37dd30e57..94f6a5571 100644
--- a/packages/order-utils/test/abi/calldata.ts
+++ b/packages/order-utils/test/abi/calldata.ts
@@ -223,44 +223,6 @@ export class Calldata {
valueBufs.push(block.toBuffer());
}
- /*
- const blockQueue = new Queue<CalldataBlock>();
- blockQueue.push(this.root);
-
- // Assign locations in breadth-first manner
- let block: CalldataBlock | undefined;
- let offset = 0;
- while ((block = blockQueue.pop()) !== undefined) {
- console.log(block.getName());
- block.setOffset(offset);
- offset += block.getSizeInBytes();
- if (block instanceof DependentCalldataBlock) {
- console.log(block.getDependency());
- blockQueue.push(block.getDependency());
- } else if (block instanceof MemberCalldataBlock) {
- _.eachRight(block.getMembers(), (member: CalldataBlock) => {
- blockQueue.pushFront(member);
- });
- }
- }
-
- console.log(this.root);
-
- // Fetch values using same technique
- const valueBufs: Buffer[] = [selectorBuffer];
- blockQueue.push(this.root);
- while ((block = blockQueue.pop()) !== undefined) {
- valueBufs.push(block.toBuffer());
-
- if (block instanceof DependentCalldataBlock) {
- blockQueue.push(block.getDependency());
- } else if (block instanceof MemberCalldataBlock) {
- _.eachRight(block.getMembers(), (member: CalldataBlock) => {
- blockQueue.pushFront(member);
- });
- }
- }*/
-
const combinedBuffers = Buffer.concat(valueBufs);
const hexValue = ethUtil.bufferToHex(combinedBuffers);
return hexValue;