diff --git a/components/cxx/test_apps/exception_no_except/main/test_exception_no_except.cpp b/components/cxx/test_apps/exception_no_except/main/test_exception_no_except.cpp index 954e73a4df..a3942613e6 100644 --- a/components/cxx/test_apps/exception_no_except/main/test_exception_no_except.cpp +++ b/components/cxx/test_apps/exception_no_except/main/test_exception_no_except.cpp @@ -20,7 +20,11 @@ extern "C" void tearDown() TEST_CASE("std::out_of_range exception when -fno-exceptions", "[cxx][reset=abort,SW_CPU_RESET]") { std::vector v(10); +// suppress warning because of this test +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Warray-bounds" v.at(20) = 42; +#pragma GCC diagnostic pop TEST_FAIL_MESSAGE("Unreachable because we are aborted on the line above"); } diff --git a/examples/cxx/experimental/esp_mqtt_cxx/components/esp_mqtt_cxx/esp_mqtt_cxx.cpp b/examples/cxx/experimental/esp_mqtt_cxx/components/esp_mqtt_cxx/esp_mqtt_cxx.cpp index b5f705b180..9a134cdb63 100644 --- a/examples/cxx/experimental/esp_mqtt_cxx/components/esp_mqtt_cxx/esp_mqtt_cxx.cpp +++ b/examples/cxx/experimental/esp_mqtt_cxx/components/esp_mqtt_cxx/esp_mqtt_cxx.cpp @@ -1,19 +1,12 @@ -// Copyright 2021 Espressif Systems (Shanghai) CO LTD -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. +/* + * SPDX-FileCopyrightText: 2021-2022 Espressif Systems (Shanghai) CO LTD + * + * SPDX-License-Identifier: Apache-2.0 + */ #include #include +#include #include "mqtt_client.h" #include "esp_log.h" diff --git a/examples/cxx/experimental/experimental_cpp_component/include/esp_event_cxx.hpp b/examples/cxx/experimental/experimental_cpp_component/include/esp_event_cxx.hpp index 3efd3bde44..41e229d16f 100644 --- a/examples/cxx/experimental/experimental_cpp_component/include/esp_event_cxx.hpp +++ b/examples/cxx/experimental/experimental_cpp_component/include/esp_event_cxx.hpp @@ -1,16 +1,8 @@ -// Copyright 2019 Espressif Systems (Shanghai) PTE LTD -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. +/* + * SPDX-FileCopyrightText: 2019-2022 Espressif Systems (Shanghai) CO LTD + * + * SPDX-License-Identifier: Apache-2.0 + */ #ifndef ESP_EVENT_CXX_H_ #define ESP_EVENT_CXX_H_ @@ -69,6 +61,7 @@ class ESPEventID { public: ESPEventID() : id(0) { } explicit ESPEventID(int32_t event_id) : id(event_id) { } + ESPEventID(const ESPEventID &rhs) : id(rhs.id) { } inline bool operator==(const ESPEventID &rhs) const { return id == rhs.get_id(); diff --git a/examples/cxx/experimental/simple_spi_rw_example/main/simple_spi_rw_example.cpp b/examples/cxx/experimental/simple_spi_rw_example/main/simple_spi_rw_example.cpp index dc41ff42f5..41cbcbc5c6 100644 --- a/examples/cxx/experimental/simple_spi_rw_example/main/simple_spi_rw_example.cpp +++ b/examples/cxx/experimental/simple_spi_rw_example/main/simple_spi_rw_example.cpp @@ -1,7 +1,7 @@ /* - * SPDX-FileCopyrightText: 2021 Espressif Systems (Shanghai) CO LTD + * SPDX-FileCopyrightText: 2021-2022 Espressif Systems (Shanghai) CO LTD * - * SPDX-License-Identifier: CC0 + * SPDX-License-Identifier: CC0-1.0 * * MPU9250 SPI Sensor C++ Example * @@ -13,6 +13,7 @@ */ #include +#include #include "spi_host_cxx.hpp" using namespace std; diff --git a/tools/ci/check_copyright_ignore.txt b/tools/ci/check_copyright_ignore.txt index f01dc46cd8..12d159e302 100644 --- a/tools/ci/check_copyright_ignore.txt +++ b/tools/ci/check_copyright_ignore.txt @@ -2054,7 +2054,6 @@ examples/cxx/experimental/esp_event_cxx/main/esp_event_cxx_example.cpp examples/cxx/experimental/esp_modem_cxx/main/simple_client.cpp examples/cxx/experimental/esp_modem_cxx/main/simple_mqtt_client.cpp examples/cxx/experimental/esp_modem_cxx/main/simple_mqtt_client.hpp -examples/cxx/experimental/esp_mqtt_cxx/components/esp_mqtt_cxx/esp_mqtt_cxx.cpp examples/cxx/experimental/esp_mqtt_cxx/components/esp_mqtt_cxx/include/esp_mqtt.hpp examples/cxx/experimental/esp_mqtt_cxx/components/esp_mqtt_cxx/include/esp_mqtt_client_config.hpp examples/cxx/experimental/esp_mqtt_cxx/ssl/main/mqtt_ssl_example.cpp @@ -2067,7 +2066,6 @@ examples/cxx/experimental/experimental_cpp_component/esp_timer_cxx.cpp examples/cxx/experimental/experimental_cpp_component/host_test/esp_timer/main/esp_timer_test.cpp examples/cxx/experimental/experimental_cpp_component/host_test/gpio/main/gpio_cxx_test.cpp examples/cxx/experimental/experimental_cpp_component/include/esp_event_api.hpp -examples/cxx/experimental/experimental_cpp_component/include/esp_event_cxx.hpp examples/cxx/experimental/experimental_cpp_component/include/esp_timer_cxx.hpp examples/cxx/experimental/experimental_cpp_component/test/test_cxx_exceptions.cpp examples/cxx/experimental/experimental_cpp_component/test/test_esp_event_cxx.cpp