Skip to content
This repository has been archived by the owner on Jun 13, 2024. It is now read-only.

add missing const to constructor invocation #878

Merged
merged 1 commit into from
Feb 1, 2023
Merged

Conversation

pq
Copy link
Contributor

@pq pq commented Feb 1, 2023

Fix missing const constructor invocation before it's flagged by an incoming linter.

See failure: https://logs.chromium.org/logs/dart/buildbucket/cr-buildbucket/8790348913643501601/+/u/analyze_flutter_gallery/stdout

Pre-launch Checklist

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I read the Tree Hygiene wiki page, which explains my responsibilities.
  • I read the Flutter Style Guide recently, and have followed its advice.
  • I signed the CLA.
  • I listed at least one issue that this PR fixes in the description above.
  • I updated/added relevant documentation (doc comments with ///).
  • I added new tests to check the change I am making, or this PR is test-exempt.
  • All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-new channel on Discord.

@pq pq changed the title add missing const add missing const to constructor invocation Feb 1, 2023
@Hixie
Copy link
Contributor

Hixie commented Feb 1, 2023

test-exempt: code refactor with no semantic change

Copy link
Member

@goderbauer goderbauer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@goderbauer
Copy link
Member

Curious: What was fixed in the linter to get this one flagged?

@pq pq merged commit b690d39 into flutter:main Feb 1, 2023
@pq pq deleted the fix_consts branch February 1, 2023 19:19
@pq
Copy link
Contributor Author

pq commented Feb 1, 2023

(For the curious, from a chat w/ @goderbauer)

Curious: What was fixed in the linter to get this one flagged?

https:/flutter/flutter/pull/119195/files#diff-437969bbec991153bb60d13acb966e6fbb8283bc2ae3c5f1c4abbe4b0160c38fL5215

Wrap is now const, so in the gallery snippet the const was able to move higher up in the tree.

copybara-service bot pushed a commit to dart-lang/sdk that referenced this pull request Feb 7, 2023
Some notes.

* There are a number of tests that should get decoupled from the linter being pulled into `DEPS`.  Instead of depending on the state of lints there, we should update the tests instead to use a more hermetic environment.  (See for example `options_rule_validator_test.dart` for how that might look.)


Downstream (blocking) fixes:

* flutter/flutter#119736
* flutter/gallery#878


Change-Id: I5671b0abde3eeda75513abaaf9fef3bcd5115f9b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/280054
Reviewed-by: Brian Wilkerson <[email protected]>
Commit-Queue: Phil Quitslund <[email protected]>
Reviewed-by: Paul Berry <[email protected]>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants