[libcxx-dev] Why does libcxx include its own files this way?

Olivier Giroux via libcxx-dev libcxx-dev at lists.llvm.org
Thu Jan 17 22:20:36 PST 2019


Inside of libcxx, you can see #include <name> being used when the library is _clearly_ intending for it to find the file that #include "name" would find. I say it’s clear because, if any other file in the world were chosen, then the library would likely fail to compile.

It looks to me like the use of #include <name> is an attempt to enforce a reservation on this name in the filesystem of the build machine. If true, then it’s kind of an overreach. I’d personally much rather if these sideways includes used #include "name" instead.

Is there a better explanation for why this is done this way?

Olivier


-----------------------------------------------------------------------------------
This email message is for the sole use of the intended recipient(s) and may contain
confidential information.  Any unauthorized review, use, disclosure or distribution
is prohibited.  If you are not the intended recipient, please contact the sender by
reply email and destroy all copies of the original message.
-----------------------------------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/libcxx-dev/attachments/20190118/142e019b/attachment-0001.html>


More information about the libcxx-dev mailing list