Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion foundry.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ evm_version = "paris"
optimizer = true
# this is a bit low, was set to 1000000 previously but this caused deployment
# code size cap to be hit.
optimizer_runs = 9000
optimizer_runs = 2000

bytecode_hash = "none"
cbor_metadata = false
Expand Down
2 changes: 1 addition & 1 deletion lib/rain.interpreter
2 changes: 1 addition & 1 deletion lib/rain.orderbook.interface
2 changes: 1 addition & 1 deletion packages/orderbook/test/js_api/raindexClient.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -829,7 +829,7 @@ describe('Rain Orderbook JS API Package Bindgen Tests - Raindex Client', async f
ratio: '0x0000000000000000000000000000000000000000000000000000000000000002',
maxInput: '0x0000000000000000000000000000000000000000000000000000000000000002',
maxOutput: '0x0000000000000000000000000000000000000000000000000000000000000001',
inverseRatio: '0xffffffda000000000000000000000000259da6542d43623d04c5112000000000',
inverseRatio: '0xffffffbd2f7a53a390f4323b0f54bbbb472fa8c5db448df40000000000000000',

formattedInverseRatio: '0.5',
formattedMaxInput: '2',
Expand Down
4 changes: 2 additions & 2 deletions src/generated/OrderBookSubParser.pointers.sol
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
pragma solidity =0.8.25;

/// @dev Hash of the known bytecode.
bytes32 constant BYTECODE_HASH = bytes32(0x14fcea81300c2900d35b488e9a0f7b9e1de913764ae6e26810568ea39e6ca651);
bytes32 constant BYTECODE_HASH = bytes32(0x465eca8482d85ed5246c5e85b7d63e794670cd4c58774dabe2086cad0ea33b11);

/// @dev The hash of the meta that describes the contract.
bytes32 constant DESCRIBED_BY_META_HASH = bytes32(0x3457291434660c589b0e6c287e12b513e5194a5129c75fa47d01ce03fbc52178);
Expand Down Expand Up @@ -50,7 +50,7 @@ bytes constant SUB_PARSER_WORD_PARSERS =
/// These positional indexes all map to the same indexes looked up in the parse
/// meta.
bytes constant OPERAND_HANDLER_FUNCTION_POINTERS =
hex"1d191d191d191d191d191d191d191d191d191d191d191d191d191d191d191d191d191d5e1e5d1d191d191d191d191d191d191d191d191d191d191d19";
hex"1cfb1cfb1cfb1cfb1cfb1cfb1cfb1cfb1cfb1cfb1cfb1cfb1cfb1cfb1cfb1cfb1cfb1d401e3f1cfb1cfb1cfb1cfb1cfb1cfb1cfb1cfb1cfb1cfb1cfb";

/// @dev Every two bytes is a function pointer for a literal parser.
/// Literal dispatches are determined by the first byte(s) of the literal
Expand Down
3 changes: 2 additions & 1 deletion tauri-app/src-tauri/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 6 additions & 6 deletions test/concrete/ob/OrderBook.clear.handleIO.revert.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -148,9 +148,9 @@ contract OrderBookClearHandleIORevertTest is OrderBookExternalRealTest {
// This is a bit fragile but the error message includes the inner
// executable bytecode only, not the outer parsed bytecode.
bytes memory aliceErr =
abi.encodeWithSelector(SourceIndexOutOfBounds.selector, 1, hex"010000020200023710000001100000");
abi.encodeWithSelector(SourceIndexOutOfBounds.selector, 1, hex"010000020200023e10000001100000");
bytes memory bobErr =
abi.encodeWithSelector(SourceIndexOutOfBounds.selector, 1, hex"010000020200023710000001100000");
abi.encodeWithSelector(SourceIndexOutOfBounds.selector, 1, hex"010000020200023e10000001100000");

checkClearOrderHandleIO(aliceString, bobString, aliceErr, bobErr);
Comment thread
thedavidmeister marked this conversation as resolved.
}
Expand All @@ -164,9 +164,9 @@ contract OrderBookClearHandleIORevertTest is OrderBookExternalRealTest {
// This is a bit fragile but the error message includes the inner
// executable bytecode only, not the outer parsed bytecode.
bytes memory aliceErr =
abi.encodeWithSelector(SourceIndexOutOfBounds.selector, 1, hex"010000020200023710000001100000");
abi.encodeWithSelector(SourceIndexOutOfBounds.selector, 1, hex"010000020200023e10000001100000");
bytes memory bobErr =
abi.encodeWithSelector(SourceIndexOutOfBounds.selector, 1, hex"010000020200023710000001100000");
abi.encodeWithSelector(SourceIndexOutOfBounds.selector, 1, hex"010000020200023e10000001100000");

checkClearOrderHandleIO(aliceString, bobString, aliceErr, bobErr);
Comment thread
thedavidmeister marked this conversation as resolved.
}
Expand All @@ -180,9 +180,9 @@ contract OrderBookClearHandleIORevertTest is OrderBookExternalRealTest {
// This is a bit fragile but the error message includes the inner
// executable bytecode only, not the outer parsed bytecode.
bytes memory aliceErr =
abi.encodeWithSelector(SourceIndexOutOfBounds.selector, 1, hex"010000020200023710000001100000");
abi.encodeWithSelector(SourceIndexOutOfBounds.selector, 1, hex"010000020200023e10000001100000");
bytes memory bobErr =
abi.encodeWithSelector(SourceIndexOutOfBounds.selector, 1, hex"010000020200023710000001100000");
abi.encodeWithSelector(SourceIndexOutOfBounds.selector, 1, hex"010000020200023e10000001100000");

checkClearOrderHandleIO(aliceString, bobString, aliceErr, bobErr);
Comment thread
thedavidmeister marked this conversation as resolved.
}
Expand Down
4 changes: 2 additions & 2 deletions test/concrete/ob/OrderBook.deposit.entask.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -232,15 +232,15 @@ contract OrderBookDepositEnactTest is OrderBookExternalRealTest {
string.concat(
usingWordsFrom,
":ensure(equal-to(deposit-vault-before() ",
preDepositAmount.toDecimalString(),
preDepositAmount.toDecimalString(9),
") \"vault balance before\");"
)
);
evals[5] = bytes(
string.concat(
usingWordsFrom,
":ensure(equal-to(deposit-vault-after() ",
preDepositAmount.add(depositAmount).toDecimalString(),
preDepositAmount.add(depositAmount).toDecimalString(9),
") \"vault balance after\");"
)
);
Comment thread
thedavidmeister marked this conversation as resolved.
Expand Down
6 changes: 3 additions & 3 deletions test/concrete/ob/OrderBook.withdraw.entask.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -377,15 +377,15 @@ contract OrderBookWithdrawEvalTest is OrderBookExternalRealTest {
string.concat(
usingWordsFrom,
":ensure(equal-to(withdraw-vault-before() ",
depositAmount.toDecimalString(),
depositAmount.toDecimalString(9),
") \"vault before\");"
)
);
evals[5] = bytes(
string.concat(
usingWordsFrom,
":ensure(equal-to(withdraw-vault-after() ",
depositAmount.sub(withdrawAmount).toDecimalString(),
depositAmount.sub(withdrawAmount).toDecimalString(9),
") \"balance after\");"
)
);
Expand All @@ -394,7 +394,7 @@ contract OrderBookWithdrawEvalTest is OrderBookExternalRealTest {
string.concat(
usingWordsFrom,
":ensure(equal-to(withdraw-target-amount() ",
LibFormatDecimalFloat.toDecimalString(targetAmount),
targetAmount.toDecimalString(9),
") \"target amount\");"
)
);
Expand Down