Skip to content

Constructor colouring on DartDocs is not working #59921

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

Closed
FMorschel opened this issue Jan 16, 2025 · 2 comments
Closed

Constructor colouring on DartDocs is not working #59921

FMorschel opened this issue Jan 16, 2025 · 2 comments
Labels
legacy-area-analyzer Use area-devexp instead.

Comments

@FMorschel
Copy link
Contributor

Originally posted in #59724:

From #59910 (comment):

Dartdoc prefers the A.foo instance member. To specifically refer to the constructor, you can use A.foo(). We should document this behavior here: https://dart.dev/tools/doc-comments/references

So for this code, you can differentiate between them:

/// A class with [A.foo] and [A.foo()]
class A {
  int foo = 0;
  A.foo();
}

But there is no colouring for A.foo() (currently being suggested correctly). [...]

Image

Also noticed the . has no colouring here. Not a big deal but it is a bit weird.

CC @DanTup

@FMorschel FMorschel added the legacy-area-analyzer Use area-devexp instead. label Jan 16, 2025
@DanTup
Copy link
Collaborator

DanTup commented Jan 16, 2025

I think this is probably the same as #47553. In the code above, there are no regions parsed for the one with the parens, so we don't provide navigation (or colouring) for it. That issue was specifically about functions, but I just tested with constructors and it seems to be the same.

(FYI @srawlins .. should we close this one as a dupe of that?)

@FMorschel
Copy link
Contributor Author

I missed it. Thanks! I'll post whatever I feel is missing there just so we have it all in one place.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
legacy-area-analyzer Use area-devexp instead.
Projects
None yet
Development

No branches or pull requests

2 participants