From 8a41766b7220724d55d1a90fbb96b6e7cd51c9cd Mon Sep 17 00:00:00 2001 From: Eric Lunderberg Date: Wed, 4 Aug 2021 15:48:31 -0500 Subject: [PATCH] [Bugfix][Target] Correct passing of target-queried bool/int parameters --- src/target/target.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/target/target.cc b/src/target/target.cc index a2a10da6d79a..f2f3fbcb0cc5 100644 --- a/src/target/target.cc +++ b/src/target/target.cc @@ -768,9 +768,9 @@ ObjectPtr TargetInternal::FromConfig(std::unordered_map(ret)); - } else if (type_info.type_index == Bool::ContainerType::_GetOrAllocRuntimeTypeIndex()) { attrs[key] = Integer(static_cast(ret)); + } else if (type_info.type_index == Bool::ContainerType::_GetOrAllocRuntimeTypeIndex()) { + attrs[key] = Bool(static_cast(ret)); } else { LOG(FATAL) << "Expected " << type_info.type_key << " parameter for attribute '" << key << "', but received integer from device api";