-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Commit
Fixes app-common and chip-tool.
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{{#unless (isInConfigList (concat ns "::" label) "EnumsNotUsedAsTypeInXML")}} | ||
static auto __attribute__((unused)) EnsureKnownEnumValue({{ns}}::{{asType label}} val) | ||
{ | ||
using EnumType = {{ns}}::{{asType label}}; | ||
switch (val) { | ||
{{#zcl_enum_items}} | ||
case EnumType::k{{asUpperCamelCase label}}: | ||
{{/zcl_enum_items}} | ||
return val; | ||
default: | ||
return EnumType::kUnknownEnumValue; | ||
} | ||
} | ||
{{/unless}} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.