Skip to content

Commit

Permalink
Address review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
bzbarsky-apple committed Nov 12, 2021
1 parent ffff7ce commit a80407c
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,6 @@
* limitations under the License.
*/

/**
* Helpers for manipulating values that are going into and out of the attribute
* store.
*/

#pragma once

#include <lib/support/TypeTraits.h>
Expand All @@ -37,7 +32,9 @@ struct NumericAttributeTraits
using StorageType = T;

// The value reserved in the value space of StorageType to represent null,
// for cases when we have a nullable value.
// for cases when we have a nullable value. This value must match the value
// excluded from the valid value range in the spec, so that we don't confuse
// valid values with null.
static constexpr StorageType kNullValue =
std::is_signed<T>::value ? std::numeric_limits<T>::min() : std::numeric_limits<T>::max();

Expand Down
2 changes: 1 addition & 1 deletion src/app/util/ember-compatibility-functions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
#include <app/reporting/Engine.h>
#include <app/reporting/reporting.h>
#include <app/util/af.h>
#include <app/util/attribute-storage-helpers.h>
#include <app/util/attribute-storage-null-handling.h>
#include <app/util/attribute-storage.h>
#include <app/util/attribute-table.h>
#include <app/util/ember-compatibility-functions.h>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
#include <app-common/zap-generated/ids/Attributes.h>
#include <app-common/zap-generated/ids/Clusters.h>
#include <app/util/af.h>
#include <app/util/attribute-storage-helpers.h>
#include <app/util/attribute-storage-null-handling.h>

namespace chip {
namespace app {
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit a80407c

Please sign in to comment.