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

Fix const declaration cosmetics and avoid use of computeNode for information analyzer already has. #1585

Merged
merged 19 commits into from
Jan 9, 2018

Conversation

jcollins-g
Copy link
Contributor

@jcollins-g jcollins-g commented Jan 4, 2018

Fixes #1576.

The constant declaration handling has been a frequent source of bugs, so this also includes an improvement on the fix for #1535 and a bit of work on #1375. Add const where appropriate and avoid reading the source code when calculating the initializer, as complicated expressions can hide information from the docs otherwise. The analyzer rationalizes them, so make use of that in at least one case and link the result. (There are more possibilities to expand the linkifier, but that can wait for a future PR).

Also fixes some inconsistencies introduced in #1581 where page titles for constants weren't indicating that they were constant.

Most of these changes have minor impacts cosmetically.

The test package's ex library list of top-level constants, before (at head):
before-tp-constants
and after:
after-tp-constants

The test package's MY_CAT constant, before:
before-mycat-constant
and after:
after-mycat-constant

The dart:io SDK library's APPEND top-level constant, before:
before-io-append
and after:
after-io-append

And finally, the dart:io SDK library's FileMode class's constant, APPEND, before:
before-filemode-append
and after:
after-filemode-append

@googlebot googlebot added the cla: yes Google CLA check succeeded. label Jan 4, 2018
@jcollins-g jcollins-g closed this Jan 4, 2018
@jcollins-g jcollins-g merged commit 1358c8f into master Jan 9, 2018
@jcollins-g jcollins-g deleted the serve-test-package-docs+const-declaration branch January 9, 2018 16:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes Google CLA check succeeded.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

dart:io APPEND field should be marked as const in Dart API Spec
3 participants