Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upborder: Avoid generating empty segments. #3056
Closed
Conversation
Instead, just add functions to add the instances directly, avoiding the intermediate allocation and deindenting a bunch of the code. This should have no behavior change.
This is a bit less invasive and should do the job. I've confirmed that all the negative sizes come from edges, when a huge radii with radius > rect.size - cw_border.width - ccw_border.width. Still we're creating a gazillion empty borders which are useless, so prevent that too.
|
r? @kvark (only last commit of course) |
|
@emilio ideally, the first commit should be left with me as an author. If you rebased on the PR, you'd have it right. |
|
So I was seeing the same failures on our automation, and I debugged again and I understand the issue now. Will file an issue, but there's no point in keeping this open for now. The TL;DR: is that nothing the output of |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
emilio commentedSep 13, 2018
•
edited by larsbergstrom
This is a bit less invasive and should do the job.
I've confirmed that all the negative sizes came from edges, when a huge radii
with radius > rect.size - cw_border.width - ccw_border.width caused avail_width to be negative.
Still we're creating a gazillion empty borders which are useless, so prevent
that too by checking in add_edge_segment and add_corner_segment.
I've confirmed that this passes the reftests that are failing in #3049, but waiting for try just to double-check.
This change is