google / s2geometry

Computational geometry and spatial indexing on the sphere
http://s2geometry.io/
Apache License 2.0
2.29k stars 302 forks source link

Fix possible warning in header #287

Closed MBkkt closed 1 year ago

MBkkt commented 1 year ago

if no defined ABSL_MIN_LOGLEVEL severity will be unused.

Because its header it's pretty inconvenient.

As an alternative solution will be make field under ifdef. But in this case layout of class will be changed, so I don't know, is it valid for you, I decide to make more simple fix.

smcallis commented 1 year ago

Seems like a reasonable workaround.

jmr commented 1 year ago

What does "possible warning" mean? Is there some compiler/set of options you actually observed a warning with?

This will all be deleted soon anyway, since absl now supports logging.

MBkkt commented 1 year ago

What does "possible warning" mean? Is there some compiler/set of options you actually observed a warning with?

Yes, gcc 11.2 with some flags, warnings about unused variable. But I think it can be avoided if we interprete s2 headers like system headers.

This will all be deleted soon anyway, since absl now supports logging.

Good we don't really use it.

MBkkt commented 1 year ago

https://github.com/arangodb/arangodb/blob/devel/3rdParty/README_maintainers.md#s2geometry

We have patch, and mostly it fix warnings