[PATCH] D51265: Headers: fix collisions with .h files of other projects

2018-08-28 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. Can you give the text of the error messages? If you're seeing a "typedef redefinition with different types" error, libclang is getting confused about the target. And parsing code for the wrong target cannot work in general. Repository: rC Clang https://reviews.ll

[PATCH] D51265: Headers: fix collisions with .h files of other projects

2018-08-27 Thread Andrew Kelley via Phabricator via cfe-commits
andrewrk marked an inline comment as done. andrewrk added a comment. In https://reviews.llvm.org/D51265#1215060, @efriedma wrote: > What is this change actually solving? Even if the typedef is actually > redundant, it shouldn't cause a compiler error: redundant typedefs are > allowed in the la

[PATCH] D51265: Headers: fix collisions with .h files of other projects

2018-08-27 Thread Eli Friedman via Phabricator via cfe-commits
efriedma edited reviewers, added: efriedma, rsmith, thakis; removed: eli.friedman, krememek, ddunbar, lattner. efriedma added a comment. What is this change actually solving? Even if the typedef is actually redundant, it shouldn't cause a compiler error: redundant typedefs are allowed in the l

[PATCH] D51265: Headers: fix collisions with .h files of other projects

2018-08-25 Thread Andrew Kelley via Phabricator via cfe-commits
andrewrk updated this revision to Diff 162574. andrewrk added a comment. Addressed review feedback Repository: rC Clang https://reviews.llvm.org/D51265 Files: lib/Headers/stdarg.h lib/Headers/stddef.h Index: lib/Headers/stddef.h =

[PATCH] D51265: Headers: fix collisions with .h files of other projects

2018-08-25 Thread Josh Junon via Phabricator via cfe-commits
Qix- added inline comments. Comment at: lib/Headers/stdarg.h:30 #ifndef _VA_LIST +#ifndef _VA_LIST_T typedef __builtin_va_list va_list; Super nit-picky but you could condense this a bit by using ``` #if !defined(_VA_LIST) && !defined(_VA_LIST_T) ``` and a sin

[PATCH] D51265: Headers: fix collisions with .h files of other projects

2018-08-25 Thread Andrew Kelley via Phabricator via cfe-commits
andrewrk created this revision. andrewrk added reviewers: eli.friedman, krememek, ddunbar, lattner. andrewrk added a project: clang. Herald added a subscriber: cfe-commits. stdarg.h: - va_list - macos _va_list.h was duplicately defining va_list. Fixed by this ifndef _VA_LIST_T - additionally def