Skip to content
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

Build signatures without trivia #1509

Open
piotmag769 opened this issue Aug 6, 2024 · 0 comments · May be fixed by #1601
Open

Build signatures without trivia #1509

piotmag769 opened this issue Aug 6, 2024 · 0 comments · May be fixed by #1601
Assignees
Milestone

Comments

@piotmag769
Copy link
Contributor

Currently signatures in scarb-doc sometimes contain trivia, particularly comments. Example:

struct MyStruct{
  /// Field.
  field: u8
}

This happens because the logic of fetching the signatures is basically getting all the text from the node with item definition. We should instead: traverse the subtree of the node, get text without trivia from each leaf, concatenate it together (remember about adding whitespaces where neccesary) and format it.

Note: if we decide to do #1426 first/in near future then this task becomes irrelevant

@maciektr maciektr added this to the Scarb Doc milestone Aug 13, 2024
@wawel37 wawel37 self-assigned this Sep 17, 2024
@wawel37 wawel37 linked a pull request Sep 17, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: In Progress
Development

Successfully merging a pull request may close this issue.

3 participants