Skip to content

docs: fix matchOrders parameter order and types in Overview#37

Open
skyc1e wants to merge 1 commit intoPolymarket:mainfrom
skyc1e:fix/docs-matchorders-params
Open

docs: fix matchOrders parameter order and types in Overview#37
skyc1e wants to merge 1 commit intoPolymarket:mainfrom
skyc1e:fix/docs-matchorders-params

Conversation

@skyc1e
Copy link
Copy Markdown

@skyc1e skyc1e commented Mar 25, 2026

Description

The pseudo-code examples in Overview.md had the first two parameters of matchOrders swapped compared to the actual function signature in CTFExchange.sol.

CTFExchange.sol signature:

function matchOrders(
    Order memory takerOrder,         // 1st: single taker order
    Order[] memory makerOrders,      // 2nd: array of maker orders
    uint256 takerFillAmount,         // 3rd: uint256
    uint256[] memory makerFillAmounts // 4th: uint256[]
)

<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> **Low Risk**
> Documentation-only changes updating `matchOrders` example calls to match the real parameter order and array types; no runtime or contract logic is affected.
> 
> **Overview**
> Updates `docs/Overview.md` to fix the pseudo-code `matchOrders` invocations in the three matching scenarios by **swapping maker/taker argument order** and ensuring the final fill-amount parameter is shown as a `uint256[]` (array) where appropriate.
> 
> <sup>Written by [Cursor Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit 7d57e15c8973a65fbb279dd3d650730875359b3b. This will update automatically on new commits. Configure [here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->

The pseudo-code examples had `makerOrder` and `takerOrder` swapped
compared to the actual function signature in CTFExchange.sol, where
the first param is `takerOrder` and the second is `makerOrders[]`.

Also added missing array brackets on the 4th parameter
(`makerFillAmounts` is `uint256[]`) in scenarios 2 and 3.

Fixes Polymarket#33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant