Skip to content

feat: Support lvalues in validation functions#1264

Open
andflo-Arm wants to merge 1 commit intomainfrom
pr/lvalue-validation
Open

feat: Support lvalues in validation functions#1264
andflo-Arm wants to merge 1 commit intomainfrom
pr/lvalue-validation

Conversation

@andflo-Arm
Copy link
Contributor

Support lvalue expressions passed to

  • error_on_format_not_in
  • error_on_data_type_not_in
  • error_on_data_layout_not_in
  • error_on_channel_not_in.

Partially-resolves: COMPMID-8697

Change-Id: Ia792500d932f92e2c79338fa537984762b66a258

Support lvalue expressions passed to
  - error_on_format_not_in
  - error_on_data_type_not_in
  - error_on_data_layout_not_in
  - error_on_channel_not_in.

Partially-resolves: COMPMID-8697
Signed-off-by: Andreas Flöjt <andreas.floejt@arm.com>
Change-Id: Ia792500d932f92e2c79338fa537984762b66a258
ARM_COMPUTE_ERROR_ON_LOC(object_format == Format::UNKNOWN, function, file, line);

const std::array<F, sizeof...(Fs)> formats_array{{std::forward<Fs>(formats)...}};
const std::array<std::decay_t<F>, sizeof...(Fs)> formats_array{{std::forward<Fs>(formats)...}};
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

<type_traits>

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We also need to <array> since you're touching it :)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And <utility> for std::forward

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants