[libunwind] r297175 - Tidy up the way we include EHHeaderParser.hpp.
Ed Schouten via cfe-commits
cfe-commits at lists.llvm.org
Wed Mar 8 07:10:08 PST 2017
Hi Marshall,
2017-03-08 15:47 GMT+01:00 Marshall Clow <mclow.lists at gmail.com>:
> I'm having trouble building libunwind this morning (on a Mac).
Ah, thanks for reporting. I only tested this on FreeBSD and CloudABI.
On those systems we don't build Unwind_AppleExtras.cpp.
> /Sources/LLVM/llvm/projects/libunwind/src/EHHeaderParser.hpp:44:32: error:
> expected a qualified name after 'typename'
> typename CFI_Parser<A>::FDE_Info *fdeInfo,
> ^
Looking at the sources, I think this change introduced the cyclic
dependency on #includes: AddressSpace.hpp -> EHHeaderParser.hpp ->
DwarfParser.hpp -> AddressSpace.hpp.
Though EHHeaderParser.hpp and DwarfParser.hpp both declare class
templates that can take LocalAddressSpace as an argument, they don't
have any actual source-level dependency on that class. We can
therefore remove the #include to AddressSpace.hpp and only do that in
Unwind_AppleExtras.cpp.
What are your thoughts on the attached patch?
--
Ed Schouten <ed at nuxi.nl>
Nuxi, 's-Hertogenbosch, the Netherlands
KvK-nr.: 62051717
-------------- next part --------------
Index: src/DwarfParser.hpp
===================================================================
--- src/DwarfParser.hpp (revision 297278)
+++ src/DwarfParser.hpp (working copy)
@@ -21,7 +21,6 @@
#include "libunwind.h"
#include "dwarf2.h"
-#include "AddressSpace.hpp"
#include "config.h"
namespace libunwind {
Index: src/EHHeaderParser.hpp
===================================================================
--- src/EHHeaderParser.hpp (revision 297278)
+++ src/EHHeaderParser.hpp (working copy)
@@ -15,7 +15,6 @@
#include "libunwind.h"
-#include "AddressSpace.hpp"
#include "DwarfParser.hpp"
namespace libunwind {
Index: src/Unwind_AppleExtras.cpp
===================================================================
--- src/Unwind_AppleExtras.cpp (revision 297278)
+++ src/Unwind_AppleExtras.cpp (working copy)
@@ -9,6 +9,7 @@
//===----------------------------------------------------------------------===//
#include "config.h"
+#include "AddressSpace.hpp"
#include "DwarfParser.hpp"
#include "unwind_ext.h"
More information about the cfe-commits
mailing list