From 213c0b05de43656ed218210f43751e7b3b23877d Mon Sep 17 00:00:00 2001 From: swan-amazon <122404367+swan-amazon@users.noreply.github.com> Date: Fri, 17 Feb 2023 16:09:01 -0800 Subject: [PATCH] Variable "_custom_impl_clusters" unused before it went out of scope When generating data model with no clusters then a build error is generated due to the "_custom_impl_clusters" variable being unused before it went out of scope. ``` ERROR at //src/app/chip_data_model.gni:192:29: Assignment had no effect. _custom_impl_clusters = [] ^ You set the variable "_custom_impl_clusters" here and it was unused before it went out of scope. ``` To prevent the issue, "_custom_impl_clusters" can be marked as not needed. --- src/app/chip_data_model.gni | 1 + 1 file changed, 1 insertion(+) diff --git a/src/app/chip_data_model.gni b/src/app/chip_data_model.gni index ff42f7c1b195ee..300a60006cea1c 100644 --- a/src/app/chip_data_model.gni +++ b/src/app/chip_data_model.gni @@ -190,6 +190,7 @@ template("chip_data_model") { } _custom_impl_clusters = [] + not_needed([ "_custom_impl_clusters" ]) # Might not be needed. if (defined(invoker.zap_clusters_with_custom_implementation)) { _custom_impl_clusters = invoker.zap_clusters_with_custom_implementation }