From 04518a28cb5c36e00051e43a2baf1da311edafc2 Mon Sep 17 00:00:00 2001 From: acezen Date: Wed, 19 Jun 2024 14:53:49 +0800 Subject: [PATCH] Fix format with clang-format-8 Signed-off-by: acezen --- cpp/include/graphar/util/filesystem.h | 8 ++++---- cpp/src/filesystem.cc | 9 +++++---- cpp/test/test_arrow_chunk_reader.cc | 3 +-- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/cpp/include/graphar/util/filesystem.h b/cpp/include/graphar/util/filesystem.h index 9f9e0947c..712a90b9a 100644 --- a/cpp/include/graphar/util/filesystem.h +++ b/cpp/include/graphar/util/filesystem.h @@ -100,8 +100,8 @@ class FileSystem { * @return A Status indicating OK if successful, or an error if unsuccessful. */ template - Status WriteValueToFile(const T& value, - const std::string& path) const noexcept; + Status WriteValueToFile(const T& value, const std::string& path) const + noexcept; /** * @brief Write a table to a file with a specific type. @@ -111,8 +111,8 @@ class FileSystem { * @return A Status indicating OK if successful, or an error if unsuccessful. */ Status WriteTableToFile(const std::shared_ptr& table, - FileType file_type, - const std::string& path) const noexcept; + FileType file_type, const std::string& path) const + noexcept; /** * Copy a file. diff --git a/cpp/src/filesystem.cc b/cpp/src/filesystem.cc index 8127a6ec6..23b9ec0b6 100644 --- a/cpp/src/filesystem.cc +++ b/cpp/src/filesystem.cc @@ -172,8 +172,8 @@ Result FileSystem::ReadFileToValue(const std::string& path) const noexcept { } template <> -Result FileSystem::ReadFileToValue( - const std::string& path) const noexcept { +Result FileSystem::ReadFileToValue(const std::string& path) const + noexcept { GAR_RETURN_ON_ARROW_ERROR_AND_ASSIGN(auto access_file, arrow_fs_->OpenInputFile(path)); GAR_RETURN_ON_ARROW_ERROR_AND_ASSIGN(auto bytes, access_file->GetSize()); @@ -311,6 +311,7 @@ Result> FileSystemFromUriOrPath( template Result FileSystem::ReadFileToValue( const std::string&) const noexcept; /// template specialization for std::string -template Status FileSystem::WriteValueToFile( - const IdType&, const std::string&) const noexcept; +template Status FileSystem::WriteValueToFile(const IdType&, + const std::string&) const + noexcept; } // namespace graphar diff --git a/cpp/test/test_arrow_chunk_reader.cc b/cpp/test/test_arrow_chunk_reader.cc index 79b6198c9..2c48272a1 100644 --- a/cpp/test/test_arrow_chunk_reader.cc +++ b/cpp/test/test_arrow_chunk_reader.cc @@ -526,8 +526,7 @@ TEST_CASE_METHOD(GlobalFixture, "JSON_TEST") { SECTION("CastDataType") { std::string prefix = test_data_dir + "/ldbc_sample/"; - std::string vertex_info_path = - prefix + "json/Person.vertex.yml"; + std::string vertex_info_path = prefix + "json/Person.vertex.yml"; std::cout << "Vertex info path: " << vertex_info_path << std::endl; auto fs = FileSystemFromUriOrPath(prefix).value(); auto yaml_content =