sui icon indicating copy to clipboard operation
sui copied to clipboard

[move] Support parsing doc comments before/after/in-between attributes

Open tzakian opened this issue 9 months ago • 1 comments

Description

Adds support for parsing doc comments with attributes either before, after, or in the middle of the doc comments.

Before, the following were all errors

/// Doc comment
#[annotation]
fun foo() { }

/// Doc comment
#[annotation]
/// Other doc comment
fun foo() { }

/// Doc comment
#[annotation]
/// Other doc comment
#[annotation]
fun foo() { }

These are now all supported, and the previous behavior of

#[annotation]
/// Doc comments
fun foo() { }

is also maintained.

Test plan

Added additional tests for both the parser, and docgen to make sure we attach doc comments correctly.

tzakian avatar May 23 '24 00:05 tzakian

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
sui-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback May 23, 2024 5:12pm
3 Ignored Deployments
Name Status Preview Comments Updated (UTC)
multisig-toolkit ⬜️ Ignored (Inspect) Visit Preview May 23, 2024 5:12pm
sui-kiosk ⬜️ Ignored (Inspect) Visit Preview May 23, 2024 5:12pm
sui-typescript-docs ⬜️ Ignored (Inspect) Visit Preview May 23, 2024 5:12pm

vercel[bot] avatar May 23 '24 00:05 vercel[bot]