Skip to content

Commit

Permalink
Revert D147231 "[reland][libc] Adds string and TestLogger classes, us…
Browse files Browse the repository at this point in the history
…e them in LibcTest"

Build bot detected a memory leak.
This reverts commit b82d04e.
  • Loading branch information
gchatelet committed Apr 3, 2023
1 parent b82d04e commit 5a55dfb
Show file tree
Hide file tree
Showing 11 changed files with 77 additions and 650 deletions.
13 changes: 0 additions & 13 deletions libc/src/__support/CPP/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -55,19 +55,6 @@ add_header_library(
libc.src.__support.common
)

add_header_library(
string
HDRS
string.h
DEPENDS
.string_view
libc.src.__support.common
libc.src.__support.integer_to_string
libc.src.string.memory_utils.memcpy_implementation
libc.src.string.memory_utils.memset_implementation
libc.src.string.string_utils
)

add_header_library(
stringstream
HDRS
Expand Down
224 changes: 0 additions & 224 deletions libc/src/__support/CPP/string.h

This file was deleted.

43 changes: 13 additions & 30 deletions libc/test/UnitTest/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,29 +1,12 @@
add_library(
TestLogger
TestLogger.cpp
TestLogger.h
)
target_include_directories(TestLogger PUBLIC ${LIBC_SOURCE_DIR})
add_dependencies(TestLogger
libc.src.__support.CPP.string
libc.src.__support.CPP.string_view
libc.src.__support.OSUtil.osutil
)

add_library(
LibcUnitTest
Test.h
LibcTest.cpp
LibcTest.h
)
target_include_directories(LibcUnitTest PUBLIC ${LIBC_SOURCE_DIR})
add_dependencies(
LibcUnitTest
libc.src.__support.CPP.string
libc.src.__support.CPP.string_view
libc.src.__support.CPP.type_traits
libc.src.__support.uint128 TestLogger)
target_link_libraries(LibcUnitTest PUBLIC libc_test_utils TestLogger)
add_dependencies(LibcUnitTest libc.src.__support.CPP.type_traits libc.src.__support.uint128)
target_link_libraries(LibcUnitTest PUBLIC libc_test_utils)

add_library(
LibcUnitTestMain
Expand All @@ -37,17 +20,17 @@ target_link_libraries(LibcUnitTestMain PUBLIC LibcUnitTest libc_test_utils)
add_header_library(
string_utils
HDRS
StringUtils.h
StringUtils.h
DEPENDS
libc.src.__support.CPP.type_traits
)

add_library(
LibcFPTestHelpers
FPExceptMatcher.cpp
FPExceptMatcher.h
FPMatcher.cpp
FPMatcher.h
FPExceptMatcher.cpp
FPExceptMatcher.h
FPMatcher.cpp
FPMatcher.h
)
target_include_directories(LibcFPTestHelpers PUBLIC ${LIBC_SOURCE_DIR})
target_link_libraries(LibcFPTestHelpers LibcUnitTest libc_test_utils)
Expand All @@ -61,8 +44,8 @@ add_dependencies(

add_library(
LibcMemoryHelpers
MemoryMatcher.h
MemoryMatcher.cpp
MemoryMatcher.h
MemoryMatcher.cpp
)
target_include_directories(LibcMemoryHelpers PUBLIC ${LIBC_SOURCE_DIR})
target_link_libraries(LibcMemoryHelpers LibcUnitTest)
Expand All @@ -74,8 +57,8 @@ add_dependencies(

add_library(
LibcPrintfHelpers
PrintfMatcher.h
PrintfMatcher.cpp
PrintfMatcher.h
PrintfMatcher.cpp
)
target_include_directories(LibcPrintfHelpers PUBLIC ${LIBC_SOURCE_DIR})
target_link_libraries(LibcPrintfHelpers LibcUnitTest)
Expand All @@ -89,8 +72,8 @@ add_dependencies(

add_library(
LibcScanfHelpers
ScanfMatcher.h
ScanfMatcher.cpp
ScanfMatcher.h
ScanfMatcher.cpp
)
target_include_directories(LibcScanfHelpers PUBLIC ${LIBC_SOURCE_DIR})
target_link_libraries(LibcScanfHelpers LibcUnitTest)
Expand Down
Loading

0 comments on commit 5a55dfb

Please sign in to comment.