Skip to content

Commit 2a0be7b

Browse files
authored
Merge pull request eclipse-iceoryx#2061 from eclipse-iceoryx/iox-1391-move-list-to-container-module
[Stacked on eclipse-iceoryx#2059] iox-eclipse-iceoryx#1391 Move list to container module
2 parents 765cfd9 + f0e20a2 commit 2a0be7b

File tree

10 files changed

+52
-26
lines changed

10 files changed

+52
-26
lines changed

.github/workflows/build-test.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ on:
77
push:
88
branches: [ master ]
99
pull_request:
10-
branches: [ master, release* ]
10+
branches: [ master, release*, iox-* ]
1111

1212
jobs:
1313
pre-flight-check:

.github/workflows/lint_pull_request.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: Code Linting on Pull-Requests
22

33
on:
44
pull_request:
5-
branches: [ master, release* ]
5+
branches: [ master, release*, iox-* ]
66

77
jobs:
88
clang-tidy-review:

iceoryx_examples/complexdata/topic_data.hpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
#define IOX_EXAMPLES_COMPLEXDATA_TOPIC_DATA_HPP
1919

2020
#include "iceoryx_dust/cxx/forward_list.hpp"
21-
#include "iceoryx_hoofs/cxx/list.hpp"
21+
#include "iox/list.hpp"
2222
#include "iox/optional.hpp"
2323
#include "iox/stack.hpp"
2424
#include "iox/string.hpp"

iceoryx_hoofs/include/iceoryx_hoofs/internal/cxx/list.inl iceoryx_hoofs/container/include/iox/detail/list.inl

+4-9
Original file line numberDiff line numberDiff line change
@@ -15,18 +15,14 @@
1515
//
1616
// SPDX-License-Identifier: Apache-2.0
1717

18-
#ifndef IOX_HOOFS_CXX_LIST_INL
19-
#define IOX_HOOFS_CXX_LIST_INL
18+
#ifndef IOX_HOOFS_CONTAINER_LIST_INL
19+
#define IOX_HOOFS_CONTAINER_LIST_INL
2020

21-
22-
#include "iceoryx_hoofs/cxx/list.hpp"
21+
#include "iox/list.hpp"
2322
#include "iox/logging.hpp"
2423

25-
2624
namespace iox
2725
{
28-
namespace cxx
29-
{
3026
/// @NOLINTJUSTIFICATION m_data fields are explicitly initialized whenever a new element is inserted
3127
/// into the list
3228
/// @NOLINTNEXTLINE(cppcoreguidelines-pro-type-member-init,hicpp-member-init)
@@ -699,7 +695,6 @@ inline bool list<T, Capacity>::isInvalidIterOrDifferentLists(const const_iterato
699695
return isInvalidIterator(iter);
700696
}
701697

702-
} // namespace cxx
703698
} // namespace iox
704699

705-
#endif // IOX_HOOFS_CXX_LIST_INL
700+
#endif // IOX_HOOFS_CONTAINER_LIST_INL

iceoryx_hoofs/include/iceoryx_hoofs/cxx/list.hpp iceoryx_hoofs/container/include/iox/list.hpp

+4-7
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515
//
1616
// SPDX-License-Identifier: Apache-2.0
1717

18-
#ifndef IOX_HOOFS_CXX_LIST_HPP
19-
#define IOX_HOOFS_CXX_LIST_HPP
18+
#ifndef IOX_HOOFS_CONTAINER_LIST_HPP
19+
#define IOX_HOOFS_CONTAINER_LIST_HPP
2020

2121
#include "iceoryx_hoofs/cxx/requires.hpp"
2222
#include "iox/uninitialized_array.hpp"
@@ -28,8 +28,6 @@
2828

2929
namespace iox
3030
{
31-
namespace cxx
32-
{
3331
/// @brief C++11 compatible bi-directional list implementation.
3432
/// @details Adjustments in the API were done to not use exceptions and serve the requirement of
3533
/// a data structure movable over shared memory.
@@ -386,9 +384,8 @@ class list
386384
size_type m_size{0U};
387385
}; // list
388386

389-
} // namespace cxx
390387
} // namespace iox
391388

392-
#include "iceoryx_hoofs/internal/cxx/list.inl"
389+
#include "iox/detail/list.inl"
393390

394-
#endif // IOX_HOOFS_CXX_LIST_HPP
391+
#endif // IOX_HOOFS_CONTAINER_LIST_HPP
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
// Copyright (c) 2023 by Mathias Kraus <elboberido@m-hias.de>. All rights reserved.
2+
//
3+
// Licensed under the Apache License, Version 2.0 (the "License");
4+
// you may not use this file except in compliance with the License.
5+
// You may obtain a copy of the License at
6+
//
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
//
9+
// Unless required by applicable law or agreed to in writing, software
10+
// distributed under the License is distributed on an "AS IS" BASIS,
11+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
// See the License for the specific language governing permissions and
13+
// limitations under the License.
14+
//
15+
// SPDX-License-Identifier: Apache-2.0
16+
17+
#ifndef IOX_HOOFS_CXX_LIST_HPP
18+
#define IOX_HOOFS_CXX_LIST_HPP
19+
20+
#include "iox/detail/deprecation_marker.hpp"
21+
#include "iox/list.hpp"
22+
23+
IOX_DEPRECATED_HEADER_SINCE(3, "Please include 'iox/list.hpp' instead.")
24+
25+
namespace iox
26+
{
27+
namespace cxx
28+
{
29+
/// @deprecated use 'iox::list' instead of 'iox::cxx::list'
30+
using iox::list;
31+
} // namespace cxx
32+
} // namespace iox
33+
34+
#endif // IOX_HOOFS_CXX_LIST_HPP

iceoryx_hoofs/test/moduletests/test_cxx_list.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,19 +15,19 @@
1515
//
1616
// SPDX-License-Identifier: Apache-2.0
1717

18-
#include "iceoryx_hoofs/cxx/list.hpp"
1918
#include "iceoryx_hoofs/error_handling/error_handling.hpp"
2019
#include "iceoryx_hoofs/testing/ctor_and_assignment_operator_test_class.hpp"
2120
#include "iceoryx_hoofs/testing/fatal_failure.hpp"
2221
#include "iox/attributes.hpp"
22+
#include "iox/list.hpp"
2323
#include "iox/logging.hpp"
2424
#include "test.hpp"
2525

2626

2727
namespace
2828
{
2929
using namespace ::testing;
30-
using namespace iox::cxx;
30+
using namespace iox;
3131
using namespace iox::testing;
3232

3333
constexpr uint64_t TESTLISTCAPACITY{10U};

iceoryx_posh/include/iceoryx_posh/internal/roudi/introspection/process_introspection.hpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,12 @@
1717
#ifndef IOX_POSH_ROUDI_INTROSPECTION_PROCESS_INTROSPECTION_HPP
1818
#define IOX_POSH_ROUDI_INTROSPECTION_PROCESS_INTROSPECTION_HPP
1919

20-
#include "iceoryx_hoofs/cxx/list.hpp"
2120
#include "iceoryx_hoofs/internal/concurrent/periodic_task.hpp"
2221
#include "iceoryx_posh/iceoryx_posh_types.hpp"
2322
#include "iceoryx_posh/internal/popo/ports/publisher_port_user.hpp"
2423
#include "iceoryx_posh/roudi/introspection_types.hpp"
2524
#include "iox/function.hpp"
25+
#include "iox/list.hpp"
2626

2727
#include <mutex>
2828

@@ -94,7 +94,7 @@ class ProcessIntrospection
9494
void send() noexcept;
9595

9696
private:
97-
using ProcessList_t = cxx::list<ProcessIntrospectionData, MAX_PROCESS_NUMBER>;
97+
using ProcessList_t = iox::list<ProcessIntrospectionData, MAX_PROCESS_NUMBER>;
9898
ProcessList_t m_processList;
9999
bool m_processListNewData{true}; // true because we want to have a valid field, even with an empty list
100100

iceoryx_posh/include/iceoryx_posh/internal/roudi/process_manager.hpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717
#ifndef IOX_POSH_ROUDI_PROCESS_MANAGER_HPP
1818
#define IOX_POSH_ROUDI_PROCESS_MANAGER_HPP
1919

20-
#include "iceoryx_hoofs/cxx/list.hpp"
2120
#include "iceoryx_hoofs/posix_wrapper/posix_access_rights.hpp"
2221
#include "iceoryx_posh/internal/mepoo/segment_manager.hpp"
2322
#include "iceoryx_posh/internal/roudi/introspection/process_introspection.hpp"
@@ -27,6 +26,7 @@
2726
#include "iceoryx_posh/mepoo/chunk_header.hpp"
2827
#include "iceoryx_posh/version/compatibility_check_level.hpp"
2928
#include "iceoryx_posh/version/version_info.hpp"
29+
#include "iox/list.hpp"
3030

3131
#include <cstdint>
3232
#include <ctime>
@@ -46,7 +46,7 @@ class ProcessManagerInterface
4646
class ProcessManager : public ProcessManagerInterface
4747
{
4848
public:
49-
using ProcessList_t = cxx::list<Process, MAX_PROCESS_NUMBER>;
49+
using ProcessList_t = iox::list<Process, MAX_PROCESS_NUMBER>;
5050
using PortConfigInfo = iox::runtime::PortConfigInfo;
5151

5252
enum class TerminationFeedback

iceoryx_posh/test/integrationtests/test_publisher_subscriber_communication.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,14 @@
1616
// SPDX-License-Identifier: Apache-2.0
1717

1818
#include "iceoryx_dust/cxx/forward_list.hpp"
19-
#include "iceoryx_hoofs/cxx/list.hpp"
2019
#include "iceoryx_hoofs/testing/barrier.hpp"
2120
#include "iceoryx_hoofs/testing/watch_dog.hpp"
2221
#include "iceoryx_posh/popo/publisher.hpp"
2322
#include "iceoryx_posh/popo/subscriber.hpp"
2423
#include "iceoryx_posh/roudi_env/minimal_roudi_config.hpp"
2524
#include "iceoryx_posh/runtime/posh_runtime.hpp"
2625
#include "iceoryx_posh/testing/roudi_gtest.hpp"
26+
#include "iox/list.hpp"
2727
#include "iox/optional.hpp"
2828
#include "iox/stack.hpp"
2929
#include "iox/string.hpp"

0 commit comments

Comments
 (0)