Minor fixes for libstdc++ 15#178601
Conversation
|
It looks like this pull request may not have tests. Please make sure to add tests or get an explicit test exemption before merging. If you are not sure if you need tests, consider this rule of thumb: the purpose of a test is to make sure someone doesn't accidentally revert the fix. Ask yourself, is there anything in your PR that you feel it is important we not accidentally revert back to how it was before your fix? Reviewers: Read the Tree Hygiene page and make sure this patch meets those guidelines before LGTMing. If you believe this PR qualifies for a test exemption, contact "@test-exemption-reviewer" in the #hackers channel in Discord (don't just cc them here, they won't see it!). The test exemption team is a small volunteer group, so all reviewers should feel empowered to ask for tests, without delegating that responsibility entirely to the test exemption group. |
There was a problem hiding this comment.
Code Review
This pull request introduces several minor fixes for compatibility with libstdc++ 15. The changes primarily involve adding necessary headers like <cstdint> and <memory> to various files, ensuring they are self-contained. Additionally, the API for Filter::Open has been updated to use std::string instead of std::string_view for file paths, which is a valid approach to resolve issues with std::ifstream. My review includes suggestions to refine this API change by using a const reference for the string parameter, which is a standard practice to prevent unnecessary copies and aligns with the project's C++ style guide.
0887ce1 to
788e7b5
Compare
| #include <fstream> | ||
| #include "third_party/abseil-cpp/absl/strings/str_cat.h" | ||
|
|
||
| absl::StatusOr<Filter> Filter::Open(std::string_view path) { |
There was a problem hiding this comment.
I don't understand this change. Why not just a std::string_view reference (with an include of <string_view>`?
There was a problem hiding this comment.
std::ifstream::open() does not accept a std::string_view argument
libstdc++ only accepts std::string and not std::string_view as an argument
788e7b5 to
64d255b
Compare
Manual roll Flutter from d81baab to 57c3f8b (38 revisions) Manual roll requested by [email protected] flutter/flutter@d81baab...57c3f8b 2025-12-17 [email protected] Add FloatingActionButtonTheme (flutter/flutter#179736) 2025-12-17 [email protected] Roll Skia from b1569739f431 to fb576bd6827a (1 revision) (flutter/flutter#179989) 2025-12-17 [email protected] Update more comments related to theme normalization (flutter/flutter#179682) 2025-12-17 [email protected] Roll Skia from cce9b86bda7d to b1569739f431 (1 revision) (flutter/flutter#179979) 2025-12-17 [email protected] Adds property passthrough for CheckboxListTile, SwitchListTile and RadioListTile (flutter/flutter#178098) 2025-12-17 [email protected] Roll Dart SDK from ca949b915846 to 3793f3d2d0c4 (2 revisions) (flutter/flutter#179973) 2025-12-17 [email protected] Roll Skia from 318400199beb to cce9b86bda7d (1 revision) (flutter/flutter#179976) 2025-12-17 [email protected] Make sure that a CupertinoTextFormFieldRow doesn't crash in 0x0 envir… (flutter/flutter#179932) 2025-12-17 [email protected] Make sure that a CupertinoTabView doesn't crash in 0x0 environment (flutter/flutter#179845) 2025-12-17 [email protected] Make sure that a CupertinoTextField doesn't crash in 0x0 environment (flutter/flutter#179865) 2025-12-17 [email protected] Make sure that a CupertinoSwitch doesn't crash in 0x0 environment (flutter/flutter#179748) 2025-12-17 [email protected] Update `BuildContext` docs to make it easier to understand (flutter/flutter#178616) 2025-12-17 [email protected] [ios][pv] quick fix to enable and re-enable web view's gesture recognizer (flutter/flutter#179908) 2025-12-17 [email protected] Deduplicate wasm dry run entries in analytics. (flutter/flutter#179970) 2025-12-17 [email protected] Roll Skia from 99899cbb415b to 318400199beb (1 revision) (flutter/flutter#179969) 2025-12-17 [email protected] Roll Skia from 2ac4a8709bc9 to 99899cbb415b (1 revision) (flutter/flutter#179968) 2025-12-17 [email protected] Roll Dart SDK from 95a92bc705d3 to ca949b915846 (6 revisions) (flutter/flutter#179967) 2025-12-17 [email protected] Add package info to wasm dry run events. (flutter/flutter#179826) 2025-12-17 [email protected] Platform View Hide/Show Integration test (flutter/flutter#179902) 2025-12-16 [email protected] Roll Skia from 61162d72343f to 2ac4a8709bc9 (14 revisions) (flutter/flutter#179961) 2025-12-16 [email protected] Roll Fuchsia Linux SDK from 433KtmJvbMyaDMJvD... to fAoyBAT99XxwPE5hL... (flutter/flutter#179960) 2025-12-16 [email protected] [ Tool ] Fix update-packages not accounting for path dependencies (flutter/flutter#179951) 2025-12-16 [email protected] ListTile fix MinIntrinsicHeight calculation (flutter/flutter#179515) 2025-12-16 [email protected] Fix pinned header in NestedScrollView (flutter/flutter#179210) 2025-12-16 [email protected] Update some comments related to theme normalization (flutter/flutter#179624) 2025-12-16 [email protected] Add Cyrillic keyboard layout support for flutter_tools terminal commands (flutter/flutter#177855) 2025-12-16 [email protected] Minor fixes for libstdc++ 15 (flutter/flutter#178601) 2025-12-16 [email protected] Feat: Add top gap for cupertino sheet (flutter/flutter#171348) 2025-12-16 [email protected] Align `Build.API_LEVELS` usage in `FlutterImageDecoder.java` with existing usage (flutter/flutter#179868) 2025-12-16 [email protected] Revert "[ios][pv] accept/reject gesture based on hitTest (with new wi… (flutter/flutter#179895) 2025-12-16 [email protected] fix: line endings for flutter/dart/flutter-dev (flutter/flutter#179912) 2025-12-16 [email protected] Platform view blur clipping - Rounded Rect (iOS) (flutter/flutter#177551) 2025-12-16 [email protected] Roll Dart SDK from 20d114f951db to 95a92bc705d3 (1 revision) (flutter/flutter#179909) 2025-12-16 [email protected] [Reland] Unmodified android sdk bundle (flutter/flutter#179920) 2025-12-16 [email protected] Roll Skia from 6903a4e65c3f to 61162d72343f (2 revisions) (flutter/flutter#179915) 2025-12-16 [email protected] Roll Packages from 2cd921c to 57725eb (1 revision) (flutter/flutter#179942) 2025-12-16 [email protected] Filter out FrameEvents/updateAcquireFence log spam from adb logcat (flutter/flutter#179884) 2025-12-16 [email protected] `flutter update-packages --force-upgrade --update-hashes` (flutter/flutter#179950) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages Please CC [email protected],[email protected] on the revert to ensure that a human is aware of the problem. ...
…0671) Manual roll Flutter from d81baab to 57c3f8b (38 revisions) Manual roll requested by [email protected] flutter/flutter@d81baab...57c3f8b 2025-12-17 [email protected] Add FloatingActionButtonTheme (flutter/flutter#179736) 2025-12-17 [email protected] Roll Skia from b1569739f431 to fb576bd6827a (1 revision) (flutter/flutter#179989) 2025-12-17 [email protected] Update more comments related to theme normalization (flutter/flutter#179682) 2025-12-17 [email protected] Roll Skia from cce9b86bda7d to b1569739f431 (1 revision) (flutter/flutter#179979) 2025-12-17 [email protected] Adds property passthrough for CheckboxListTile, SwitchListTile and RadioListTile (flutter/flutter#178098) 2025-12-17 [email protected] Roll Dart SDK from ca949b915846 to 3793f3d2d0c4 (2 revisions) (flutter/flutter#179973) 2025-12-17 [email protected] Roll Skia from 318400199beb to cce9b86bda7d (1 revision) (flutter/flutter#179976) 2025-12-17 [email protected] Make sure that a CupertinoTextFormFieldRow doesn't crash in 0x0 envir… (flutter/flutter#179932) 2025-12-17 [email protected] Make sure that a CupertinoTabView doesn't crash in 0x0 environment (flutter/flutter#179845) 2025-12-17 [email protected] Make sure that a CupertinoTextField doesn't crash in 0x0 environment (flutter/flutter#179865) 2025-12-17 [email protected] Make sure that a CupertinoSwitch doesn't crash in 0x0 environment (flutter/flutter#179748) 2025-12-17 [email protected] Update `BuildContext` docs to make it easier to understand (flutter/flutter#178616) 2025-12-17 [email protected] [ios][pv] quick fix to enable and re-enable web view's gesture recognizer (flutter/flutter#179908) 2025-12-17 [email protected] Deduplicate wasm dry run entries in analytics. (flutter/flutter#179970) 2025-12-17 [email protected] Roll Skia from 99899cbb415b to 318400199beb (1 revision) (flutter/flutter#179969) 2025-12-17 [email protected] Roll Skia from 2ac4a8709bc9 to 99899cbb415b (1 revision) (flutter/flutter#179968) 2025-12-17 [email protected] Roll Dart SDK from 95a92bc705d3 to ca949b915846 (6 revisions) (flutter/flutter#179967) 2025-12-17 [email protected] Add package info to wasm dry run events. (flutter/flutter#179826) 2025-12-17 [email protected] Platform View Hide/Show Integration test (flutter/flutter#179902) 2025-12-16 [email protected] Roll Skia from 61162d72343f to 2ac4a8709bc9 (14 revisions) (flutter/flutter#179961) 2025-12-16 [email protected] Roll Fuchsia Linux SDK from 433KtmJvbMyaDMJvD... to fAoyBAT99XxwPE5hL... (flutter/flutter#179960) 2025-12-16 [email protected] [ Tool ] Fix update-packages not accounting for path dependencies (flutter/flutter#179951) 2025-12-16 [email protected] ListTile fix MinIntrinsicHeight calculation (flutter/flutter#179515) 2025-12-16 [email protected] Fix pinned header in NestedScrollView (flutter/flutter#179210) 2025-12-16 [email protected] Update some comments related to theme normalization (flutter/flutter#179624) 2025-12-16 [email protected] Add Cyrillic keyboard layout support for flutter_tools terminal commands (flutter/flutter#177855) 2025-12-16 [email protected] Minor fixes for libstdc++ 15 (flutter/flutter#178601) 2025-12-16 [email protected] Feat: Add top gap for cupertino sheet (flutter/flutter#171348) 2025-12-16 [email protected] Align `Build.API_LEVELS` usage in `FlutterImageDecoder.java` with existing usage (flutter/flutter#179868) 2025-12-16 [email protected] Revert "[ios][pv] accept/reject gesture based on hitTest (with new wi… (flutter/flutter#179895) 2025-12-16 [email protected] fix: line endings for flutter/dart/flutter-dev (flutter/flutter#179912) 2025-12-16 [email protected] Platform view blur clipping - Rounded Rect (iOS) (flutter/flutter#177551) 2025-12-16 [email protected] Roll Dart SDK from 20d114f951db to 95a92bc705d3 (1 revision) (flutter/flutter#179909) 2025-12-16 [email protected] [Reland] Unmodified android sdk bundle (flutter/flutter#179920) 2025-12-16 [email protected] Roll Skia from 6903a4e65c3f to 61162d72343f (2 revisions) (flutter/flutter#179915) 2025-12-16 [email protected] Roll Packages from 2cd921c to 57725eb (1 revision) (flutter/flutter#179942) 2025-12-16 [email protected] Filter out FrameEvents/updateAcquireFence log spam from adb logcat (flutter/flutter#179884) 2025-12-16 [email protected] `flutter update-packages --force-upgrade --update-hashes` (flutter/flutter#179950) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages Please CC [email protected],[email protected] on the revert to ensure that a human is aware of the problem. ...
Replace this paragraph with a description of what this PR is changing or adding, and why. Consider including before/after screenshots.
This adds some includes and changes an API in an internal tool to use
std::stringinstead ofstd::string_viewfor a path, fixing builds with libstdc++ 15List which issues are fixed by this PR. You must list at least one issue. An issue is not required if the PR fixes something trivial like a typo.
If you had to change anything in the flutter/tests repo, include a link to the migration guide as per the breaking change policy.
Pre-launch Checklist
///).If you need help, consider asking for advice on the #hackers-new channel on Discord.
Note: The Flutter team is currently trialing the use of Gemini Code Assist for GitHub. Comments from the
gemini-code-assistbot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed.