-
Notifications
You must be signed in to change notification settings - Fork 118
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support custom errors #342
Comments
Thanks for pointing this out! I'd like to fix this, hope I get the time. 🙏 |
@PaulRBerg This is solved in the upcoming rewrite (#350). I'll try it out with the contract that you shared! Can you share an example of what you'd like the output to look like for errors? |
Glad to hear.
Well custom errors are annotated with NatSpec comments, just like any other function. So treating them as functions would be a good solution to start with. The only difference would be that the errors would be placed under another upper header "Custom Errors", and not under "Functions". To take ## Custom Errors
### BalanceSheet__BorrowMaxBonds
\```solidity
error BalanceSheet__BorrowMaxBonds(
IHToken bond,
uint256 newBondListLength,
uint256 maxBonds
);
\```
Emitted when the account exceeds the maximum numbers of bonds permitted. |
Custom errors cannot be configured to be included in the Markdown report.
When I run solidity-docgen over a contract with lots of custom errors (such as the BalanceSheet), the custom errors are not included in the output.
The text was updated successfully, but these errors were encountered: