abseil / abseil/abseil-cpp

[Bug]: Compilation error on mac: xcode command line interface 15.3

Open
#1,648 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
18.1k
Forks
3.2k
Avg merge
20h 36m
Merged PRs (30d)
1

Description

### Describe the issue

external/com_google_absl/absl/strings/internal/str_split_internal.h:286:25: error: initializing pointer member 'text_' with the stack address of parameter 'input_text' [-Werror,-Wdangling-field]
: text_(std::move(input_text)),
^~~~~~~~~~
external/com_google_absl/absl/strings/str_split.h:520:10: note: in instantiation of member function 'absl::lts_20240116::strings_internal::Splitter>::Splitter' requested here
return strings_internal::Splitter' requested here
for (absl::string_view line_text : absl::StrSplit(format_string, '\n')) {
^
external/com_google_absl/absl/strings/internal/str_split_internal.h:472:14: note: pointer member declared here
StringType text_;
^

### Steps to reproduce the problem

checkout google/or-tools on the main branch
compile with bazel

### What version of Abseil are you using?

20240116.1

### What operating system and version are you using?

Darwin XXX 23.4.0 Darwin Kernel Version 23.4.0: Fri Mar 15 00:11:05 PDT 2024; root:xnu-10063.101.17~1/RELEASE_X86_64 x86_64

### What compiler and version are you using?

Apple clang version 12.0.5 (clang-1205.0.22.11)
Target: x86_64-apple-darwin23.4.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin

### What build system are you using?

bazel 7.1.1

### Additional context

_No response_

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.