[libcxx-commits] [PATCH] D132787: [libc++] Avoids self references in transitive include test.
Mark de Wever via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Sat Aug 27 04:00:05 PDT 2022
Mordante created this revision.
Mordante added a reviewer: ldionne.
Herald added subscribers: miyuki, arphaman.
Herald added a project: All.
Mordante requested review of this revision.
Herald added a project: libc++.
Herald added a subscriber: libcxx-commits.
Herald added a reviewer: libc++.
The output of --trace-includes starts with the header whose includes are
being processed. Since the sanitize script processed all lines this
include was added to the list of transitive includes. This looks odd
since it implies all headers have a cyclic dependency on themselves.
This change removes this self-include.
Instead of just dropping the first line extract that header and use it
to guard against cyclic dependencies in the header itself.
The regex used has a small improvement; don't capture groups that aren't
extracted.
Depends on D132284 <https://reviews.llvm.org/D132284>
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D132787
Files:
libcxx/test/libcxx/transitive_includes.sanitize.py
libcxx/test/libcxx/transitive_includes/cxx03/expected.algorithm
libcxx/test/libcxx/transitive_includes/cxx03/expected.any
libcxx/test/libcxx/transitive_includes/cxx03/expected.array
libcxx/test/libcxx/transitive_includes/cxx03/expected.atomic
libcxx/test/libcxx/transitive_includes/cxx03/expected.barrier
libcxx/test/libcxx/transitive_includes/cxx03/expected.bit
libcxx/test/libcxx/transitive_includes/cxx03/expected.bitset
libcxx/test/libcxx/transitive_includes/cxx03/expected.cassert
libcxx/test/libcxx/transitive_includes/cxx03/expected.ccomplex
libcxx/test/libcxx/transitive_includes/cxx03/expected.cctype
libcxx/test/libcxx/transitive_includes/cxx03/expected.cerrno
libcxx/test/libcxx/transitive_includes/cxx03/expected.cfenv
libcxx/test/libcxx/transitive_includes/cxx03/expected.cfloat
libcxx/test/libcxx/transitive_includes/cxx03/expected.charconv
libcxx/test/libcxx/transitive_includes/cxx03/expected.chrono
libcxx/test/libcxx/transitive_includes/cxx03/expected.cinttypes
libcxx/test/libcxx/transitive_includes/cxx03/expected.ciso646
libcxx/test/libcxx/transitive_includes/cxx03/expected.climits
libcxx/test/libcxx/transitive_includes/cxx03/expected.clocale
libcxx/test/libcxx/transitive_includes/cxx03/expected.cmath
libcxx/test/libcxx/transitive_includes/cxx03/expected.codecvt
libcxx/test/libcxx/transitive_includes/cxx03/expected.compare
libcxx/test/libcxx/transitive_includes/cxx03/expected.complex
libcxx/test/libcxx/transitive_includes/cxx03/expected.concepts
libcxx/test/libcxx/transitive_includes/cxx03/expected.condition_variable
libcxx/test/libcxx/transitive_includes/cxx03/expected.coroutine
libcxx/test/libcxx/transitive_includes/cxx03/expected.csetjmp
libcxx/test/libcxx/transitive_includes/cxx03/expected.csignal
libcxx/test/libcxx/transitive_includes/cxx03/expected.cstdarg
libcxx/test/libcxx/transitive_includes/cxx03/expected.cstdbool
libcxx/test/libcxx/transitive_includes/cxx03/expected.cstddef
libcxx/test/libcxx/transitive_includes/cxx03/expected.cstdint
libcxx/test/libcxx/transitive_includes/cxx03/expected.cstdio
libcxx/test/libcxx/transitive_includes/cxx03/expected.cstdlib
libcxx/test/libcxx/transitive_includes/cxx03/expected.cstring
libcxx/test/libcxx/transitive_includes/cxx03/expected.ctgmath
libcxx/test/libcxx/transitive_includes/cxx03/expected.ctime
libcxx/test/libcxx/transitive_includes/cxx03/expected.cuchar
libcxx/test/libcxx/transitive_includes/cxx03/expected.cwchar
libcxx/test/libcxx/transitive_includes/cxx03/expected.cwctype
libcxx/test/libcxx/transitive_includes/cxx03/expected.deque
libcxx/test/libcxx/transitive_includes/cxx03/expected.exception
libcxx/test/libcxx/transitive_includes/cxx03/expected.execution
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_algorithm
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_coroutine
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_deque
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_forward_list
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_functional
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_iterator
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_list
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_map
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_memory_resource
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_propagate_const
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_regex
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_set
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_simd
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_string
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_type_traits
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_unordered_map
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_unordered_set
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_utility
libcxx/test/libcxx/transitive_includes/cxx03/expected.experimental_vector
libcxx/test/libcxx/transitive_includes/cxx03/expected.ext_hash_map
libcxx/test/libcxx/transitive_includes/cxx03/expected.ext_hash_set
libcxx/test/libcxx/transitive_includes/cxx03/expected.filesystem
libcxx/test/libcxx/transitive_includes/cxx03/expected.format
libcxx/test/libcxx/transitive_includes/cxx03/expected.forward_list
libcxx/test/libcxx/transitive_includes/cxx03/expected.fstream
libcxx/test/libcxx/transitive_includes/cxx03/expected.functional
libcxx/test/libcxx/transitive_includes/cxx03/expected.future
libcxx/test/libcxx/transitive_includes/cxx03/expected.initializer_list
libcxx/test/libcxx/transitive_includes/cxx03/expected.iomanip
libcxx/test/libcxx/transitive_includes/cxx03/expected.ios
libcxx/test/libcxx/transitive_includes/cxx03/expected.iosfwd
libcxx/test/libcxx/transitive_includes/cxx03/expected.iostream
libcxx/test/libcxx/transitive_includes/cxx03/expected.istream
libcxx/test/libcxx/transitive_includes/cxx03/expected.iterator
libcxx/test/libcxx/transitive_includes/cxx03/expected.latch
libcxx/test/libcxx/transitive_includes/cxx03/expected.limits
libcxx/test/libcxx/transitive_includes/cxx03/expected.list
libcxx/test/libcxx/transitive_includes/cxx03/expected.locale
libcxx/test/libcxx/transitive_includes/cxx03/expected.map
libcxx/test/libcxx/transitive_includes/cxx03/expected.memory
libcxx/test/libcxx/transitive_includes/cxx03/expected.mutex
libcxx/test/libcxx/transitive_includes/cxx03/expected.new
libcxx/test/libcxx/transitive_includes/cxx03/expected.numbers
libcxx/test/libcxx/transitive_includes/cxx03/expected.numeric
libcxx/test/libcxx/transitive_includes/cxx03/expected.optional
libcxx/test/libcxx/transitive_includes/cxx03/expected.ostream
libcxx/test/libcxx/transitive_includes/cxx03/expected.queue
libcxx/test/libcxx/transitive_includes/cxx03/expected.random
libcxx/test/libcxx/transitive_includes/cxx03/expected.ranges
libcxx/test/libcxx/transitive_includes/cxx03/expected.ratio
libcxx/test/libcxx/transitive_includes/cxx03/expected.regex
libcxx/test/libcxx/transitive_includes/cxx03/expected.scoped_allocator
libcxx/test/libcxx/transitive_includes/cxx03/expected.semaphore
libcxx/test/libcxx/transitive_includes/cxx03/expected.set
libcxx/test/libcxx/transitive_includes/cxx03/expected.shared_mutex
libcxx/test/libcxx/transitive_includes/cxx03/expected.span
libcxx/test/libcxx/transitive_includes/cxx03/expected.sstream
libcxx/test/libcxx/transitive_includes/cxx03/expected.stack
libcxx/test/libcxx/transitive_includes/cxx03/expected.stdexcept
libcxx/test/libcxx/transitive_includes/cxx03/expected.streambuf
libcxx/test/libcxx/transitive_includes/cxx03/expected.string
libcxx/test/libcxx/transitive_includes/cxx03/expected.string_view
libcxx/test/libcxx/transitive_includes/cxx03/expected.strstream
libcxx/test/libcxx/transitive_includes/cxx03/expected.system_error
libcxx/test/libcxx/transitive_includes/cxx03/expected.thread
libcxx/test/libcxx/transitive_includes/cxx03/expected.tuple
libcxx/test/libcxx/transitive_includes/cxx03/expected.type_traits
libcxx/test/libcxx/transitive_includes/cxx03/expected.typeindex
libcxx/test/libcxx/transitive_includes/cxx03/expected.typeinfo
libcxx/test/libcxx/transitive_includes/cxx03/expected.unordered_map
libcxx/test/libcxx/transitive_includes/cxx03/expected.unordered_set
libcxx/test/libcxx/transitive_includes/cxx03/expected.utility
libcxx/test/libcxx/transitive_includes/cxx03/expected.valarray
libcxx/test/libcxx/transitive_includes/cxx03/expected.variant
libcxx/test/libcxx/transitive_includes/cxx03/expected.vector
libcxx/test/libcxx/transitive_includes/cxx03/expected.version
libcxx/test/libcxx/transitive_includes/cxx11/expected.algorithm
libcxx/test/libcxx/transitive_includes/cxx11/expected.any
libcxx/test/libcxx/transitive_includes/cxx11/expected.array
libcxx/test/libcxx/transitive_includes/cxx11/expected.atomic
libcxx/test/libcxx/transitive_includes/cxx11/expected.barrier
libcxx/test/libcxx/transitive_includes/cxx11/expected.bit
libcxx/test/libcxx/transitive_includes/cxx11/expected.bitset
libcxx/test/libcxx/transitive_includes/cxx11/expected.cassert
libcxx/test/libcxx/transitive_includes/cxx11/expected.ccomplex
libcxx/test/libcxx/transitive_includes/cxx11/expected.cctype
libcxx/test/libcxx/transitive_includes/cxx11/expected.cerrno
libcxx/test/libcxx/transitive_includes/cxx11/expected.cfenv
libcxx/test/libcxx/transitive_includes/cxx11/expected.cfloat
libcxx/test/libcxx/transitive_includes/cxx11/expected.charconv
libcxx/test/libcxx/transitive_includes/cxx11/expected.chrono
libcxx/test/libcxx/transitive_includes/cxx11/expected.cinttypes
libcxx/test/libcxx/transitive_includes/cxx11/expected.ciso646
libcxx/test/libcxx/transitive_includes/cxx11/expected.climits
libcxx/test/libcxx/transitive_includes/cxx11/expected.clocale
libcxx/test/libcxx/transitive_includes/cxx11/expected.cmath
libcxx/test/libcxx/transitive_includes/cxx11/expected.codecvt
libcxx/test/libcxx/transitive_includes/cxx11/expected.compare
libcxx/test/libcxx/transitive_includes/cxx11/expected.complex
libcxx/test/libcxx/transitive_includes/cxx11/expected.concepts
libcxx/test/libcxx/transitive_includes/cxx11/expected.condition_variable
libcxx/test/libcxx/transitive_includes/cxx11/expected.coroutine
libcxx/test/libcxx/transitive_includes/cxx11/expected.csetjmp
libcxx/test/libcxx/transitive_includes/cxx11/expected.csignal
libcxx/test/libcxx/transitive_includes/cxx11/expected.cstdarg
libcxx/test/libcxx/transitive_includes/cxx11/expected.cstdbool
libcxx/test/libcxx/transitive_includes/cxx11/expected.cstddef
libcxx/test/libcxx/transitive_includes/cxx11/expected.cstdint
libcxx/test/libcxx/transitive_includes/cxx11/expected.cstdio
libcxx/test/libcxx/transitive_includes/cxx11/expected.cstdlib
libcxx/test/libcxx/transitive_includes/cxx11/expected.cstring
libcxx/test/libcxx/transitive_includes/cxx11/expected.ctgmath
libcxx/test/libcxx/transitive_includes/cxx11/expected.ctime
libcxx/test/libcxx/transitive_includes/cxx11/expected.cuchar
libcxx/test/libcxx/transitive_includes/cxx11/expected.cwchar
libcxx/test/libcxx/transitive_includes/cxx11/expected.cwctype
libcxx/test/libcxx/transitive_includes/cxx11/expected.deque
libcxx/test/libcxx/transitive_includes/cxx11/expected.exception
libcxx/test/libcxx/transitive_includes/cxx11/expected.execution
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_algorithm
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_coroutine
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_deque
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_forward_list
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_functional
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_iterator
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_list
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_map
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_memory_resource
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_propagate_const
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_regex
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_set
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_simd
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_string
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_type_traits
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_unordered_map
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_unordered_set
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_utility
libcxx/test/libcxx/transitive_includes/cxx11/expected.experimental_vector
libcxx/test/libcxx/transitive_includes/cxx11/expected.ext_hash_map
libcxx/test/libcxx/transitive_includes/cxx11/expected.ext_hash_set
libcxx/test/libcxx/transitive_includes/cxx11/expected.filesystem
libcxx/test/libcxx/transitive_includes/cxx11/expected.format
libcxx/test/libcxx/transitive_includes/cxx11/expected.forward_list
libcxx/test/libcxx/transitive_includes/cxx11/expected.fstream
libcxx/test/libcxx/transitive_includes/cxx11/expected.functional
libcxx/test/libcxx/transitive_includes/cxx11/expected.future
libcxx/test/libcxx/transitive_includes/cxx11/expected.initializer_list
libcxx/test/libcxx/transitive_includes/cxx11/expected.iomanip
libcxx/test/libcxx/transitive_includes/cxx11/expected.ios
libcxx/test/libcxx/transitive_includes/cxx11/expected.iosfwd
libcxx/test/libcxx/transitive_includes/cxx11/expected.iostream
libcxx/test/libcxx/transitive_includes/cxx11/expected.istream
libcxx/test/libcxx/transitive_includes/cxx11/expected.iterator
libcxx/test/libcxx/transitive_includes/cxx11/expected.latch
libcxx/test/libcxx/transitive_includes/cxx11/expected.limits
libcxx/test/libcxx/transitive_includes/cxx11/expected.list
libcxx/test/libcxx/transitive_includes/cxx11/expected.locale
libcxx/test/libcxx/transitive_includes/cxx11/expected.map
libcxx/test/libcxx/transitive_includes/cxx11/expected.memory
libcxx/test/libcxx/transitive_includes/cxx11/expected.mutex
libcxx/test/libcxx/transitive_includes/cxx11/expected.new
libcxx/test/libcxx/transitive_includes/cxx11/expected.numbers
libcxx/test/libcxx/transitive_includes/cxx11/expected.numeric
libcxx/test/libcxx/transitive_includes/cxx11/expected.optional
libcxx/test/libcxx/transitive_includes/cxx11/expected.ostream
libcxx/test/libcxx/transitive_includes/cxx11/expected.queue
libcxx/test/libcxx/transitive_includes/cxx11/expected.random
libcxx/test/libcxx/transitive_includes/cxx11/expected.ranges
libcxx/test/libcxx/transitive_includes/cxx11/expected.ratio
libcxx/test/libcxx/transitive_includes/cxx11/expected.regex
libcxx/test/libcxx/transitive_includes/cxx11/expected.scoped_allocator
libcxx/test/libcxx/transitive_includes/cxx11/expected.semaphore
libcxx/test/libcxx/transitive_includes/cxx11/expected.set
libcxx/test/libcxx/transitive_includes/cxx11/expected.shared_mutex
libcxx/test/libcxx/transitive_includes/cxx11/expected.span
libcxx/test/libcxx/transitive_includes/cxx11/expected.sstream
libcxx/test/libcxx/transitive_includes/cxx11/expected.stack
libcxx/test/libcxx/transitive_includes/cxx11/expected.stdexcept
libcxx/test/libcxx/transitive_includes/cxx11/expected.streambuf
libcxx/test/libcxx/transitive_includes/cxx11/expected.string
libcxx/test/libcxx/transitive_includes/cxx11/expected.string_view
libcxx/test/libcxx/transitive_includes/cxx11/expected.strstream
libcxx/test/libcxx/transitive_includes/cxx11/expected.system_error
libcxx/test/libcxx/transitive_includes/cxx11/expected.thread
libcxx/test/libcxx/transitive_includes/cxx11/expected.tuple
libcxx/test/libcxx/transitive_includes/cxx11/expected.type_traits
libcxx/test/libcxx/transitive_includes/cxx11/expected.typeindex
libcxx/test/libcxx/transitive_includes/cxx11/expected.typeinfo
libcxx/test/libcxx/transitive_includes/cxx11/expected.unordered_map
libcxx/test/libcxx/transitive_includes/cxx11/expected.unordered_set
libcxx/test/libcxx/transitive_includes/cxx11/expected.utility
libcxx/test/libcxx/transitive_includes/cxx11/expected.valarray
libcxx/test/libcxx/transitive_includes/cxx11/expected.variant
libcxx/test/libcxx/transitive_includes/cxx11/expected.vector
libcxx/test/libcxx/transitive_includes/cxx11/expected.version
libcxx/test/libcxx/transitive_includes/cxx14/expected.algorithm
libcxx/test/libcxx/transitive_includes/cxx14/expected.any
libcxx/test/libcxx/transitive_includes/cxx14/expected.array
libcxx/test/libcxx/transitive_includes/cxx14/expected.atomic
libcxx/test/libcxx/transitive_includes/cxx14/expected.barrier
libcxx/test/libcxx/transitive_includes/cxx14/expected.bit
libcxx/test/libcxx/transitive_includes/cxx14/expected.bitset
libcxx/test/libcxx/transitive_includes/cxx14/expected.cassert
libcxx/test/libcxx/transitive_includes/cxx14/expected.ccomplex
libcxx/test/libcxx/transitive_includes/cxx14/expected.cctype
libcxx/test/libcxx/transitive_includes/cxx14/expected.cerrno
(465 more files...)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D132787.456107.patch
Type: text/x-patch
Size: 251797 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20220827/7c85f185/attachment-0001.bin>
More information about the libcxx-commits
mailing list