google / google/s2geometry

Warnings compiling with bazel on macOS

Open
#493 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
2.7k
Forks
357
Avg merge
11h 4m
Merged PRs (30d)
1

Description

```
% bazel test ...

s2/util/math/exactfloat/exactfloat_test.cc:109:8: warning: unused function 'scalbn' [-Wunused-function]
double scalbn(double a, int exp) {
^
s2/util/math/exactfloat/exactfloat_test.cc:113:8: warning: unused function 'scalbln' [-Wunused-function]
double scalbln(double a, long exp) {
^
2 warnings generated.
INFO: From Compiling s2/s2closest_edge_query_test.cc:
s2/s2closest_edge_query_test.cc:342:9: warning: unused type alias 'Result' [-Wunused-local-typedef]
using Result = S2ClosestEdgeQuery::Result;
^
1 warning generated.
INFO: From Compiling s2/s2shapeutil_coding_test.cc:
s2/s2shapeutil_coding_test.cc:62:30: warning: 'FullDecodeShapeFactory' is deprecated: Use version that accepts S2Error to detect encoding errors [-Wdeprecated-declarations]
&decoder, s2shapeutil::FullDecodeShapeFactory(&decoder)));
^
./s2/s2shapeutil_coding.h:181:3: note: 'FullDecodeShapeFactory' has been explicitly marked deprecated here
[[deprecated("Use version that accepts S2Error to detect encoding errors")]]
^
s2/s2shapeutil_coding_test.cc:74:24: warning: 'HexStringToBytes' is deprecated: Use the HexStringToBytes() that returns a bool [-Wdeprecated-declarations]
string bytes = absl::HexStringToBytes(
^
external/abseil-cpp~/absl/strings/escaping.h:173:1: note: 'HexStringToBytes' has been explicitly marked deprecated here
ABSL_DEPRECATED("Use the HexStringToBytes() that returns a bool")
^
external/abseil-cpp~/absl/base/attributes.h:689:49: note: expanded from macro 'ABSL_DEPRECATED'
#define ABSL_DEPRECATED(message) __attribute__((deprecated(message)))
^
s2/s2shapeutil_coding_test.cc:92:30: warning: 'FullDecodeShapeFactory' is deprecated: Use version that accepts S2Error to detect encoding errors [-Wdeprecated-declarations]
&decoder, s2shapeutil::FullDecodeShapeFactory(&decoder)));
^
./s2/s2shapeutil_coding.h:181:3: note: 'FullDecodeShapeFactory' has been explicitly marked deprecated here
[[deprecated("Use version that accepts S2Error to detect encoding errors")]]
^
3 warnings generated.
INFO: From Compiling s2/s2lax_polygon_shape_test.cc:
s2/s2lax_polygon_shape_test.cc:350:19: warning: loop variable '[e, i, j]' creates a copy from type 'std::tuple const' [-Wrange-loop-construct]
for (const auto [e, i, j] : edges) {
^
s2/s2lax_polygon_shape_test.cc:350:8: note: use reference type 'std::tuple const &' to prevent copying
for (const auto [e, i, j] : edges) {
^~~~~~~~~~~~~~~~~~~~~~
&
1 warning generated.
INFO: From Compiling s2/encoded_s2shape_index_test.cc:
s2/encoded_s2shape_index_test.cc:330:44: warning: 'LazyDecodeShapeFactory' is deprecated: Use version that accepts S2Error to detect encoding errors [-Wdeprecated-declarations]
index_.Init(&decoder, s2shapeutil::LazyDecodeShapeFactory(&decoder)));
^
./s2/s2shapeutil_coding.h:188:3: note: 'LazyDecodeShapeFactory' has been explicitly marked deprecated here
[[deprecated("Use version that accepts S2Error to detect encoding errors")]]
^
s2/encoded_s2shape_index_test.cc:375:24: warning: 'HexStringToBytes' is deprecated: Use the HexStringToBytes() that returns a bool [-Wdeprecated-declarations]
string bytes = absl::HexStringToBytes(
^
external/abseil-cpp~/absl/strings/escaping.h:173:1: note: 'HexStringToBytes' has been explicitly marked deprecated here
ABSL_DEPRECATED("Use the HexStringToBytes() that returns a bool")
^
external/abseil-cpp~/absl/base/attributes.h:689:49: note: expanded from macro 'ABSL_DEPRECATED'
#define ABSL_DEPRECATED(message) __attribute__((deprecated(message)))
^
s2/encoded_s2shape_index_test.cc:381:42: warning: 'FullDecodeShapeFactory' is deprecated: Use version that accepts S2Error to detect encoding errors [-Wdeprecated-declarations]
actual.Init(&decoder, s2shapeutil::FullDecodeShapeFactory(&decoder)));
^
./s2/s2shapeutil_coding.h:181:3: note: 'FullDecodeShapeFactory' has been explicitly marked deprecated here
[[deprecated("Use version that accepts S2Error to detect encoding errors")]]
^
3 warnings generated.
INFO: From Compiling s2/mutable_s2shape_index_test.cc:
s2/mutable_s2shape_index_test.cc:817:47: warning: 'FullDecodeShapeFactory' is deprecated: Use version that accepts S2Error to detect encoding errors [-Wdeprecated-declarations]
bool ok = index.Init(&decoder, s2shapeutil::FullDecodeShapeFactory(&decoder));
^
./s2/s2shapeutil_coding.h:181:3: note: 'FullDecodeShapeFactory' has been explicitly marked deprecated here
[[deprecated("Use version that accepts S2Error to detect encoding errors")]]
^
1 warning generated.
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.