aboutsummaryrefslogtreecommitdiffstats
path: root/packages/contracts/src
diff options
context:
space:
mode:
Diffstat (limited to 'packages/contracts/src')
-rw-r--r--packages/contracts/src/2.0.0/protocol/Exchange/MixinExchangeCore.sol8
-rw-r--r--packages/contracts/src/2.0.0/protocol/Exchange/MixinMatchOrders.sol3
-rw-r--r--packages/contracts/src/2.0.0/protocol/Exchange/MixinSignatureValidator.sol1
-rw-r--r--packages/contracts/src/2.0.0/protocol/Exchange/interfaces/IMatchOrders.sol1
4 files changed, 3 insertions, 10 deletions
diff --git a/packages/contracts/src/2.0.0/protocol/Exchange/MixinExchangeCore.sol b/packages/contracts/src/2.0.0/protocol/Exchange/MixinExchangeCore.sol
index cf53c3176..ec84b1e19 100644
--- a/packages/contracts/src/2.0.0/protocol/Exchange/MixinExchangeCore.sol
+++ b/packages/contracts/src/2.0.0/protocol/Exchange/MixinExchangeCore.sol
@@ -374,21 +374,19 @@ contract MixinExchangeCore is
returns (FillResults memory fillResults)
{
// Compute proportional transfer amounts
- // TODO: All three are multiplied by the same fraction. This can
- // potentially be optimized.
fillResults.takerAssetFilledAmount = takerAssetFilledAmount;
fillResults.makerAssetFilledAmount = getPartialAmount(
- fillResults.takerAssetFilledAmount,
+ takerAssetFilledAmount,
order.takerAssetAmount,
order.makerAssetAmount
);
fillResults.makerFeePaid = getPartialAmount(
- fillResults.takerAssetFilledAmount,
+ takerAssetFilledAmount,
order.takerAssetAmount,
order.makerFee
);
fillResults.takerFeePaid = getPartialAmount(
- fillResults.takerAssetFilledAmount,
+ takerAssetFilledAmount,
order.takerAssetAmount,
order.takerFee
);
diff --git a/packages/contracts/src/2.0.0/protocol/Exchange/MixinMatchOrders.sol b/packages/contracts/src/2.0.0/protocol/Exchange/MixinMatchOrders.sol
index ba687543a..56b309a1b 100644
--- a/packages/contracts/src/2.0.0/protocol/Exchange/MixinMatchOrders.sol
+++ b/packages/contracts/src/2.0.0/protocol/Exchange/MixinMatchOrders.sol
@@ -41,7 +41,6 @@ contract MixinMatchOrders is
/// @param leftSignature Proof that order was created by the left maker.
/// @param rightSignature Proof that order was created by the right maker.
/// @return matchedFillResults Amounts filled and fees paid by maker and taker of matched orders.
- /// TODO: Make this function external once supported by Solidity (See Solidity Issues #3199, #1603)
function matchOrders(
LibOrder.Order memory leftOrder,
LibOrder.Order memory rightOrder,
@@ -184,7 +183,6 @@ contract MixinMatchOrders is
leftTakerAssetFilledAmount = leftTakerAssetAmountRemaining;
// The right order receives an amount proportional to how much was spent.
- // TODO: Can we ensure rounding error is in the correct direction?
rightTakerAssetFilledAmount = getPartialAmount(
rightOrder.takerAssetAmount,
rightOrder.makerAssetAmount,
@@ -195,7 +193,6 @@ contract MixinMatchOrders is
rightTakerAssetFilledAmount = rightTakerAssetAmountRemaining;
// The left order receives an amount proportional to how much was spent.
- // TODO: Can we ensure rounding error is in the correct direction?
leftTakerAssetFilledAmount = getPartialAmount(
rightOrder.makerAssetAmount,
rightOrder.takerAssetAmount,
diff --git a/packages/contracts/src/2.0.0/protocol/Exchange/MixinSignatureValidator.sol b/packages/contracts/src/2.0.0/protocol/Exchange/MixinSignatureValidator.sol
index 822701459..ac7382715 100644
--- a/packages/contracts/src/2.0.0/protocol/Exchange/MixinSignatureValidator.sol
+++ b/packages/contracts/src/2.0.0/protocol/Exchange/MixinSignatureValidator.sol
@@ -91,7 +91,6 @@ contract MixinSignatureValidator is
view
returns (bool isValid)
{
- // TODO: Domain separation: make hash depend on role. (Taker sig should not be valid as maker sig, etc.)
require(
signature.length > 0,
"LENGTH_GREATER_THAN_0_REQUIRED"
diff --git a/packages/contracts/src/2.0.0/protocol/Exchange/interfaces/IMatchOrders.sol b/packages/contracts/src/2.0.0/protocol/Exchange/interfaces/IMatchOrders.sol
index cea5adbbb..73447f3ae 100644
--- a/packages/contracts/src/2.0.0/protocol/Exchange/interfaces/IMatchOrders.sol
+++ b/packages/contracts/src/2.0.0/protocol/Exchange/interfaces/IMatchOrders.sol
@@ -33,7 +33,6 @@ contract IMatchOrders {
/// @param leftSignature Proof that order was created by the left maker.
/// @param rightSignature Proof that order was created by the right maker.
/// @return matchedFillResults Amounts filled and fees paid by maker and taker of matched orders.
- /// TODO: Make this function external once supported by Solidity (See Solidity Issues #3199, #1603)
function matchOrders(
LibOrder.Order memory leftOrder,
LibOrder.Order memory rightOrder,