-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix #10958: buggy handling of embedded NUL chars
(cherry picked from commit 1d90e97) ref PR #10991 Conflicts: base/string.jl base/utf8.jl base/utf8proc.jl test/unicode.jl
- Loading branch information
Showing
4 changed files
with
11 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
b192bf0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is failing for some reason on the Launchpad buildd servers on
v0.3.8
; I'm investigating....b192bf0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
buggy system wcwidth maybe?
b192bf0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Possibly. I'm trying submitting a build on
trusty
instead ofprecise
to see if that makes a difference. Building the deb's locally on mytrusty
desktop doesn't hit this issue.b192bf0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Have you benchmarked the change to strwidth? That looks like it might make things a lot slower, and from what I learned recently, I think you might do better to get rid of u8_strwidth entirely, and rewrite charwidth in Julia, instead of calling wcwidth.
b192bf0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note that this is a commit on release-0.3, strictly backporting the bugfix. On master, charwidth no longer calls wcwidth, the functionality has been added to utf8proc. If this causes a performance regression that is fixable in a non-disruptive way we might consider PR's against release-0.3, but we'd rather err on the conservative side with the release branch.
b192bf0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's still happening on
trusty
, so I'm not sure what's going on here.b192bf0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@stevengj I haven't been able to narrow down why this is happening. Do you have any ideas?
b192bf0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe change the test to
in order to work around buggy
wcwidth
s?b192bf0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great, that worked. Thanks!
b192bf0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should we be committing that to release-0.3?
b192bf0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.