Commit e42d9766 authored by Victor Zverovich's avatar Victor Zverovich Committed by Facebook Github Bot

Fix building of targets using f14_hash with modules

Summary:
This fixes building of targets such as `folly:dynamic` that contain `F14Map.h`
includes with modules (`mode/dev-mod`). Previously they failed with the
following error:

```
folly/container/F14Map.h:37:10: error: use of private header from outside its
module: 'folly/container/F14Map-pre.h' [-Wprivate-header]
         ^
```

Reviewed By: shixiao

Differential Revision: D9144188

fbshipit-source-id: 0476f88ce2373c8b9fbf148a2e0532ff92b2477a
parent e2db8003
...@@ -403,7 +403,7 @@ if (BUILD_TESTS) ...@@ -403,7 +403,7 @@ if (BUILD_TESTS)
# EnumerateTest.cpp since it uses macros to define tests. # EnumerateTest.cpp since it uses macros to define tests.
#TEST enumerate_test SOURCES EnumerateTest.cpp #TEST enumerate_test SOURCES EnumerateTest.cpp
TEST evicting_cache_map_test SOURCES EvictingCacheMapTest.cpp TEST evicting_cache_map_test SOURCES EvictingCacheMapTest.cpp
TEST f14_pre_test SOURCES F14PreTest.cpp TEST f14_fwd_test SOURCES F14FwdTest.cpp
TEST f14_map_test SOURCES F14MapTest.cpp TEST f14_map_test SOURCES F14MapTest.cpp
TEST f14_set_test SOURCES F14SetTest.cpp TEST f14_set_test SOURCES F14SetTest.cpp
TEST foreach_test SOURCES ForeachTest.cpp TEST foreach_test SOURCES ForeachTest.cpp
......
...@@ -74,9 +74,9 @@ nobase_follyinclude_HEADERS = \ ...@@ -74,9 +74,9 @@ nobase_follyinclude_HEADERS = \
container/Iterator.h \ container/Iterator.h \
container/Enumerate.h \ container/Enumerate.h \
container/EvictingCacheMap.h \ container/EvictingCacheMap.h \
container/F14Map-pre.h \ container/F14Map-fwd.h \
container/F14Map.h \ container/F14Map.h \
container/F14Set-pre.h \ container/F14Set-fwd.h \
container/F14Set.h \ container/F14Set.h \
container/Foreach.h \ container/Foreach.h \
container/Foreach-inl.h \ container/Foreach-inl.h \
......
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
#include <folly/lang/Exception.h> #include <folly/lang/Exception.h>
#include <folly/lang/SafeAssert.h> #include <folly/lang/SafeAssert.h>
#include <folly/container/F14Map-pre.h> #include <folly/container/F14Map-fwd.h>
#include <folly/container/detail/F14Policy.h> #include <folly/container/detail/F14Policy.h>
#include <folly/container/detail/F14Table.h> #include <folly/container/detail/F14Table.h>
......
...@@ -31,7 +31,7 @@ ...@@ -31,7 +31,7 @@
#include <folly/lang/SafeAssert.h> #include <folly/lang/SafeAssert.h>
#include <folly/container/F14Set-pre.h> #include <folly/container/F14Set-fwd.h>
#include <folly/container/detail/F14Policy.h> #include <folly/container/detail/F14Policy.h>
#include <folly/container/detail/F14Table.h> #include <folly/container/detail/F14Table.h>
......
...@@ -14,8 +14,8 @@ ...@@ -14,8 +14,8 @@
* limitations under the License. * limitations under the License.
*/ */
#include <folly/container/F14Map-pre.h> #include <folly/container/F14Map-fwd.h>
#include <folly/container/F14Set-pre.h> #include <folly/container/F14Set-fwd.h>
#include <folly/portability/GTest.h> #include <folly/portability/GTest.h>
namespace { namespace {
...@@ -23,7 +23,7 @@ template <typename TContainer> ...@@ -23,7 +23,7 @@ template <typename TContainer>
void foo(TContainer*) {} void foo(TContainer*) {}
} // namespace } // namespace
TEST(F14Pre, simple) { TEST(F14Fwd, simple) {
using namespace folly; using namespace folly;
foo<F14NodeMap<int, int>>(nullptr); foo<F14NodeMap<int, int>>(nullptr);
foo<F14ValueMap<int, int>>(nullptr); foo<F14ValueMap<int, int>>(nullptr);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment