This is an archive of the discontinued LLVM Phabricator instance.

[libc++] Granularize <type_traits> includes
ClosedPublic

Authored by philnik on Mar 5 2023, 5:31 AM.

Details

Reviewers
ldionne
Mordante
Group Reviewers
Restricted Project
Restricted Project
Commits
rG0a4aa8a122aa: [libc++] Granularize <type_traits> includes

Diff Detail

Event Timeline

philnik created this revision.Mar 5 2023, 5:31 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 5 2023, 5:31 AM
Herald added a subscriber: smeenai. · View Herald Transcript
philnik requested review of this revision.Mar 5 2023, 5:31 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 5 2023, 5:31 AM
Herald added a reviewer: Restricted Project. · View Herald Transcript
philnik updated this revision to Diff 502473.Mar 5 2023, 1:57 PM

Try to fix CI

Herald added a project: Restricted Project. · View Herald TranscriptMar 5 2023, 1:57 PM
Herald added a reviewer: Restricted Project. · View Herald Transcript
ldionne accepted this revision.Mar 6 2023, 9:03 AM
ldionne added a subscriber: Restricted Project.

LGTM w/ green CI.

Pinging vendors just for heads up, since this one might break a few users. type_traits is very common and some folks may have started compiling with -std=c++2b already.

This revision is now accepted and ready to land.Mar 6 2023, 9:03 AM
philnik updated this revision to Diff 503095.Mar 7 2023, 10:48 AM

Try to fix CI

philnik updated this revision to Diff 503343.Mar 8 2023, 6:13 AM

Try to fix CI

philnik updated this revision to Diff 503394.Mar 8 2023, 8:37 AM

Next try

This revision was landed with ongoing or failed builds.Mar 8 2023, 1:05 PM
This revision was automatically updated to reflect the committed changes.

Is it only me that see problems like

******************** TEST 'llvm-libc++-shared.cfg.in :: libcxx/transitive_includes.sh.cpp' FAILED ********************

with this patch?

I get

$ ":" "RUN: at line 557"
note: command had no output on stdout or stderr
$ "diff" "-w" "/repo/uabelho/dev-main/libcxx/test/libcxx/transitive_includes/cxx2b.csv" "/repo/uabelho/dev-main/llvm/build-all-builtins/runtimes/runtimes-x86_64-unknown-linux-gnu-bins/test/libcxx/Output/transitive_includes.sh.cpp.dir/t.tmp/transitive_includes.csv"
# command output:
*** /repo/uabelho/dev-main/libcxx/test/libcxx/transitive_includes/cxx2b.csv
--- /repo/uabelho/dev-main/llvm/build-all-builtins/runtimes/runtimes-x86_64-unknown-linux-gnu-bins/test/libcxx/Output/transitive_includes.sh.cpp.dir/t.tmp/transitive_includes.csv
***************
*** 245,251 ****
  formatstring
  formatstring_view
  formattuple
- formattype_traits
  formatvector
  formatversion
  forward_listcompare
--- 245,250 ----

error: command failed with exit status: 1

Is it only me that see problems like

******************** TEST 'llvm-libc++-shared.cfg.in :: libcxx/transitive_includes.sh.cpp' FAILED ********************

with this patch?

I get

$ ":" "RUN: at line 557"
note: command had no output on stdout or stderr
$ "diff" "-w" "/repo/uabelho/dev-main/libcxx/test/libcxx/transitive_includes/cxx2b.csv" "/repo/uabelho/dev-main/llvm/build-all-builtins/runtimes/runtimes-x86_64-unknown-linux-gnu-bins/test/libcxx/Output/transitive_includes.sh.cpp.dir/t.tmp/transitive_includes.csv"
# command output:
*** /repo/uabelho/dev-main/libcxx/test/libcxx/transitive_includes/cxx2b.csv
--- /repo/uabelho/dev-main/llvm/build-all-builtins/runtimes/runtimes-x86_64-unknown-linux-gnu-bins/test/libcxx/Output/transitive_includes.sh.cpp.dir/t.tmp/transitive_includes.csv
***************
*** 245,251 ****
  formatstring
  formatstring_view
  formattuple
- formattype_traits
  formatvector
  formatversion
  forward_listcompare
--- 245,250 ----

error: command failed with exit status: 1

Seems to be fixed in https://reviews.llvm.org/D145651

I submitted https://github.com/llvm/llvm-project/commit/8227349f7e4f1a6ceb4cceb464c8f4420ff1dd0a to address errors we started seeing in <optional> after this. Leaving a comment here so the author can take a look and check if this is reasonable.