Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(627)

Issue 1584313010: Fix newline normalization in _PhysicalFile.readAsStringSync(). (Closed)

Created:
4 years, 11 months ago by Paul Berry
Modified:
4 years, 11 months ago
Reviewers:
Brian Wilkerson
CC:
reviews_dartlang.org
Base URL:
git@github.com:dart-lang/sdk.git@master
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Fix newline normalization in _PhysicalFile.readAsStringSync(). Most clients of _PhysicalFile read the file by translating it into a Source object using createSource() and then reading it using FileBasedSource.contentsFromFile, which normalizes newlines using FileBasedSource.fileReadMode. However, a few clients read the file directly using _PhysicalFile.readAsStringSync(), which wasn't doing the normalization. This CL adds the normalization to that code path. One such client was the code generation logic for summaries; this caused code generation to produce different results on Windows, which led to a test failure. Fixes #25470. R=brianwilkerson@google.com Committed: https://github.com/dart-lang/sdk/commit/3dcef185d65c5bbe98162624ef4ddc49571702e2

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1 line, -2 lines) Patch
M pkg/analyzer/lib/file_system/physical_file_system.dart View 1 chunk +1 line, -1 line 0 comments Download
M pkg/pkg.status View 1 chunk +0 lines, -1 line 0 comments Download

Messages

Total messages: 5 (2 generated)
Paul Berry
4 years, 11 months ago (2016-01-15 20:48:19 UTC) #2
Brian Wilkerson
LGTM
4 years, 11 months ago (2016-01-15 20:51:47 UTC) #3
Paul Berry
4 years, 11 months ago (2016-01-15 20:54:26 UTC) #5
Message was sent while issue was closed.
Committed patchset #1 (id:1) manually as
3dcef185d65c5bbe98162624ef4ddc49571702e2 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698