Skip to content

Commit

Permalink
remove the header src/app/util/common.h (#32320)
Browse files Browse the repository at this point in the history
* remove `src/app/util/common.h

* Fix some typos

* Remove some references of util/common.h

* Fix up comment

* Fix lint - a file got removed

* Make the paths to the files full-paths
  • Loading branch information
andy31415 authored and pull[bot] committed May 3, 2024
1 parent f5b4f92 commit 2410924
Show file tree
Hide file tree
Showing 7 changed files with 8 additions and 41 deletions.
1 change: 0 additions & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,6 @@ jobs:
--known-failure app/util/attribute-table.h \
--known-failure app/util/binding-table.cpp \
--known-failure app/util/binding-table.h \
--known-failure app/util/common.h \
--known-failure app/util/config.h \
--known-failure app/util/DataModelHandler.cpp \
--known-failure app/util/DataModelHandler.h \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@

#include "AppConfig.h"
#include "AppTask.h"
#include "app/util/common.h"

#include <app-common/zap-generated/attributes/Accessors.h>
#include <lib/support/logging/CHIPLogging.h>

Expand Down
3 changes: 0 additions & 3 deletions src/app/clusters/identify-server/identify-server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,7 @@
#include <app-common/zap-generated/ids/Commands.h>
#include <app/CommandHandler.h>
#include <app/ConcreteCommandPath.h>

#include <app/util/af.h>
#include <app/util/common.h>
#include <array>
#include <lib/support/CodeUtils.h>
#include <platform/CHIPDeviceLayer.h>
#include <tracing/macros.h>
Expand Down
9 changes: 3 additions & 6 deletions src/app/util/attribute-storage.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,12 @@
* limitations under the License.
*/

#include "app/util/common.h"
#include <app/util/attribute-storage.h>

#include <app/AttributePersistenceProvider.h>
#include <app/InteractionModelEngine.h>
#include <app/reporting/reporting.h>
#include <app/util/af.h>
#include <app/util/attribute-storage.h>
#include <app/util/config.h>
#include <app/util/generic-callbacks.h>
#include <lib/core/CHIPConfig.h>
Expand All @@ -36,10 +36,7 @@ using chip::Protocols::InteractionModel::Status;
// - zap-generated/callback.h is needed because endpoint_config will call the
// corresponding callbacks (via GENERATED_FUNCTION_ARRAYS) and the include
// for it is:
// util/common.h
// -> util/af.h
// -> util/config.h
// -> zap-generated/endpoint_config.h
// util/config.h -> zap-generated/endpoint_config.h
#include <app-common/zap-generated/callback.h>

using namespace chip;
Expand Down
6 changes: 1 addition & 5 deletions src/app/util/attribute-table.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,9 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/

// this file contains all the common includes for clusters in the zcl-util
#include <app/util/attribute-table.h>

#include <app/util/attribute-storage.h>

// for pulling in defines dealing with EITHER server or client
#include "app/util/common.h"
#include <app/util/config.h>
#include <app/util/generic-callbacks.h>
#include <app/util/odd-sized-integers.h>
Expand Down
24 changes: 0 additions & 24 deletions src/app/util/common.h

This file was deleted.

4 changes: 3 additions & 1 deletion src/app/util/util.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,14 @@
* limitations under the License.
*/

#include "app/util/common.h"
#include <app/util/util.h>

#include <app-common/zap-generated/attribute-type.h>
#include <app-common/zap-generated/attributes/Accessors.h>
#include <app-common/zap-generated/ids/Clusters.h>
#include <app-common/zap-generated/print-cluster.h>
#include <app/util/af.h>
#include <app/util/attribute-storage.h>
#include <app/util/config.h>
#include <app/util/generic-callbacks.h>
#include <lib/core/CHIPConfig.h>
Expand Down

0 comments on commit 2410924

Please sign in to comment.