Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Porting bug #77

Open
adnanutayim opened this issue Jun 21, 2021 · 0 comments
Open

Porting bug #77

adnanutayim opened this issue Jun 21, 2021 · 0 comments

Comments

@adnanutayim
Copy link

adnanutayim commented Jun 21, 2021

Hello there,

Thanks for implementing S2 in golang!

We found what seemed to be a small porting issue in Loop.go
We noticed that Loop.Contains(o *Loop) returns false sometimes when o is properly contained. We traced this issue to hasCrossingRelation().
This function doesn't share the same logical control flow with the original c++ version.

In the go version, currently it returns false when the crossing target for A is satisfied. We believe it should return false when the crossing target is not satisfied.
So this line might need a not operator at the beginning so it looks like this:

 if !containsCenterMatches(aClipped, l.aCrossingTarget) {...}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant