Skip to content

Problem with old style named constants #713

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
Janamou opened this issue Jul 23, 2015 · 6 comments
Closed

Problem with old style named constants #713

Janamou opened this issue Jul 23, 2015 · 6 comments
Assignees
Labels
P2 A bug or feature request we're likely to work on type-bug Incorrect behavior (everything from a crash to more subtle misbehavior)
Milestone

Comments

@Janamou
Copy link

Janamou commented Jul 23, 2015

When I generate the documentation for a script:

const String TYPE_NICE = "nice";
const String TYPE_VERY_NICE = "very_nice";

/// Main function uses [TYPE_NICE] and [TYPE_VERY_NICE].
main(List<String> args) {
}

Then there is a problem with constant of a name TYPE_VERY_NICE. I found out that the reason is that when I use more than one underscore, the constant is written with brackets.

Output of the comment in the documentation looks like this:
Main function uses TYPE_NICE and [TYPE_VERY_NICE].

To see it you need to go to the detail of the function in the documentation.

Same problem with the old docgen: dart-lang/sdk#23883

@sethladd sethladd added type-bug Incorrect behavior (everything from a crash to more subtle misbehavior) P1 A high priority bug; for example, a single project is unusable or has many test failures labels Jul 23, 2015
@sethladd sethladd added this to the Branch milestone Jul 23, 2015
@sethladd
Copy link
Contributor

Thanks for the report! We'll take a look.

@alan-knight
Copy link

This is probably due to the markdown parser being run first and interpreting the name as TYPEVERYNICE, or something in that vein.

@sethladd sethladd added P2 A bug or feature request we're likely to work on and removed P1 A high priority bug; for example, a single project is unusable or has many test failures labels Jul 27, 2015
@sethladd
Copy link
Contributor

sethladd commented Aug 1, 2015

@alan-knight you have a good memory :)

@devoncarew this one is available if you're interested.

@devoncarew devoncarew self-assigned this Aug 1, 2015
@sethladd sethladd assigned sethladd and unassigned devoncarew Aug 3, 2015
@sethladd
Copy link
Contributor

sethladd commented Aug 3, 2015

Taking a look today.

Sub-issue #761

@sethladd
Copy link
Contributor

sethladd commented Aug 5, 2015

We think the issue with multiple underscores is in the markdown package. Tracking that separately here: #768

@sethladd
Copy link
Contributor

sethladd commented Aug 5, 2015

I'm going to close this out because we've split this issue into two, one we've addressed now and the other we'll address in the markdown package.

Thank you so much for this report!

@sethladd sethladd closed this as completed Aug 5, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P2 A bug or feature request we're likely to work on type-bug Incorrect behavior (everything from a crash to more subtle misbehavior)
Projects
None yet
Development

No branches or pull requests

4 participants