[libcxx-commits] [libcxx] [libc++][TZDB] Makes implementation experimental. (PR #95657)

Mark de Wever via libcxx-commits libcxx-commits at lists.llvm.org
Sat Jul 6 03:06:48 PDT 2024


https://github.com/mordante updated https://github.com/llvm/llvm-project/pull/95657

>From cbe55b4238edf3f9f617d2e3107937d16a807e58 Mon Sep 17 00:00:00 2001
From: Mark de Wever <koraq at xs4all.nl>
Date: Sat, 15 Jun 2024 13:54:59 +0200
Subject: [PATCH] [libc++][TZDB] Makes implementation experimental.

This moves the files to libcxx/src/experimental/ as discussed in #90394.

Fixes: https://github.com/llvm/llvm-project/issues/94902
---
 libcxx/src/CMakeLists.txt                        | 16 ++++++++--------
 .../src/{ => experimental}/chrono_exception.cpp  |  0
 .../include/tzdb/time_zone_private.h             |  0
 .../include/tzdb/types_private.h                 |  0
 .../include/tzdb/tzdb_list_private.h             |  0
 .../include/tzdb/tzdb_private.h                  |  0
 libcxx/src/{ => experimental}/time_zone.cpp      |  0
 libcxx/src/{ => experimental}/tzdb.cpp           |  0
 libcxx/src/{ => experimental}/tzdb_list.cpp      |  0
 .../time/time.zone/time.zone.db/rules.pass.cpp   |  2 +-
 .../time/time.zone/time.zone.db/zones.pass.cpp   |  2 +-
 11 files changed, 10 insertions(+), 10 deletions(-)
 rename libcxx/src/{ => experimental}/chrono_exception.cpp (100%)
 rename libcxx/src/{ => experimental}/include/tzdb/time_zone_private.h (100%)
 rename libcxx/src/{ => experimental}/include/tzdb/types_private.h (100%)
 rename libcxx/src/{ => experimental}/include/tzdb/tzdb_list_private.h (100%)
 rename libcxx/src/{ => experimental}/include/tzdb/tzdb_private.h (100%)
 rename libcxx/src/{ => experimental}/time_zone.cpp (100%)
 rename libcxx/src/{ => experimental}/tzdb.cpp (100%)
 rename libcxx/src/{ => experimental}/tzdb_list.cpp (100%)

diff --git a/libcxx/src/CMakeLists.txt b/libcxx/src/CMakeLists.txt
index b34f9e614ae0b..0ae58a10c879c 100644
--- a/libcxx/src/CMakeLists.txt
+++ b/libcxx/src/CMakeLists.txt
@@ -342,16 +342,16 @@ endif()
 
 if (LIBCXX_ENABLE_LOCALIZATION AND LIBCXX_ENABLE_FILESYSTEM AND LIBCXX_ENABLE_TIME_ZONE_DATABASE)
   list(APPEND LIBCXX_EXPERIMENTAL_SOURCES
-    include/tzdb/time_zone_private.h
-    include/tzdb/types_private.h
-    include/tzdb/tzdb_list_private.h
-    include/tzdb/tzdb_private.h
+    experimental/include/tzdb/time_zone_private.h
+    experimental/include/tzdb/types_private.h
+    experimental/include/tzdb/tzdb_list_private.h
+    experimental/include/tzdb/tzdb_private.h
     # TODO TZDB The exception could be moved in chrono once the TZDB library
     # is no longer experimental.
-    chrono_exception.cpp
-    time_zone.cpp
-    tzdb.cpp
-    tzdb_list.cpp
+    experimental/chrono_exception.cpp
+    experimental/time_zone.cpp
+    experimental/tzdb.cpp
+    experimental/tzdb_list.cpp
     )
 endif()
 
diff --git a/libcxx/src/chrono_exception.cpp b/libcxx/src/experimental/chrono_exception.cpp
similarity index 100%
rename from libcxx/src/chrono_exception.cpp
rename to libcxx/src/experimental/chrono_exception.cpp
diff --git a/libcxx/src/include/tzdb/time_zone_private.h b/libcxx/src/experimental/include/tzdb/time_zone_private.h
similarity index 100%
rename from libcxx/src/include/tzdb/time_zone_private.h
rename to libcxx/src/experimental/include/tzdb/time_zone_private.h
diff --git a/libcxx/src/include/tzdb/types_private.h b/libcxx/src/experimental/include/tzdb/types_private.h
similarity index 100%
rename from libcxx/src/include/tzdb/types_private.h
rename to libcxx/src/experimental/include/tzdb/types_private.h
diff --git a/libcxx/src/include/tzdb/tzdb_list_private.h b/libcxx/src/experimental/include/tzdb/tzdb_list_private.h
similarity index 100%
rename from libcxx/src/include/tzdb/tzdb_list_private.h
rename to libcxx/src/experimental/include/tzdb/tzdb_list_private.h
diff --git a/libcxx/src/include/tzdb/tzdb_private.h b/libcxx/src/experimental/include/tzdb/tzdb_private.h
similarity index 100%
rename from libcxx/src/include/tzdb/tzdb_private.h
rename to libcxx/src/experimental/include/tzdb/tzdb_private.h
diff --git a/libcxx/src/time_zone.cpp b/libcxx/src/experimental/time_zone.cpp
similarity index 100%
rename from libcxx/src/time_zone.cpp
rename to libcxx/src/experimental/time_zone.cpp
diff --git a/libcxx/src/tzdb.cpp b/libcxx/src/experimental/tzdb.cpp
similarity index 100%
rename from libcxx/src/tzdb.cpp
rename to libcxx/src/experimental/tzdb.cpp
diff --git a/libcxx/src/tzdb_list.cpp b/libcxx/src/experimental/tzdb_list.cpp
similarity index 100%
rename from libcxx/src/tzdb_list.cpp
rename to libcxx/src/experimental/tzdb_list.cpp
diff --git a/libcxx/test/libcxx/time/time.zone/time.zone.db/rules.pass.cpp b/libcxx/test/libcxx/time/time.zone/time.zone.db/rules.pass.cpp
index 73f4dbd59af9a..7d9759320c535 100644
--- a/libcxx/test/libcxx/time/time.zone/time.zone.db/rules.pass.cpp
+++ b/libcxx/test/libcxx/time/time.zone/time.zone.db/rules.pass.cpp
@@ -17,7 +17,7 @@
 // Tests the IANA database rules parsing and operations.
 // This is not part of the public tzdb interface.
 // The test uses private implementation headers.
-// ADDITIONAL_COMPILE_FLAGS: -I %{libcxx-dir}/src/include
+// ADDITIONAL_COMPILE_FLAGS: -I %{libcxx-dir}/src/experimental/include
 
 #include <chrono>
 #include <fstream>
diff --git a/libcxx/test/libcxx/time/time.zone/time.zone.db/zones.pass.cpp b/libcxx/test/libcxx/time/time.zone/time.zone.db/zones.pass.cpp
index 6d436d61357b3..ded89ed808e17 100644
--- a/libcxx/test/libcxx/time/time.zone/time.zone.db/zones.pass.cpp
+++ b/libcxx/test/libcxx/time/time.zone/time.zone.db/zones.pass.cpp
@@ -17,7 +17,7 @@
 // Tests the IANA database zones parsing and operations.
 // This is not part of the public tzdb interface.
 // The test uses private implementation headers.
-// ADDITIONAL_COMPILE_FLAGS: -I %{libcxx-dir}/src/include
+// ADDITIONAL_COMPILE_FLAGS: -I %{libcxx-dir}/src/experimental/include
 
 #include <cassert>
 #include <chrono>



More information about the libcxx-commits mailing list