From f49f3b4f9dbbf78ecbf74dd51574054d2e6a072f Mon Sep 17 00:00:00 2001 From: Allen Guo Date: Mon, 29 Aug 2022 11:52:34 +0800 Subject: [PATCH] fix compile (#45441) --- paddle/fluid/platform/device/ipu/ipu_compiler.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/paddle/fluid/platform/device/ipu/ipu_compiler.cc b/paddle/fluid/platform/device/ipu/ipu_compiler.cc index 7eaf25f5dfd..5eb318d9daa 100644 --- a/paddle/fluid/platform/device/ipu/ipu_compiler.cc +++ b/paddle/fluid/platform/device/ipu/ipu_compiler.cc @@ -42,6 +42,7 @@ struct CustomOpAttrVisitor { void operator()(int v) const { attrs_->emplace(attr_name_, v); } void operator()(float v) const { attrs_->emplace(attr_name_, v); } + void operator()(double v) const { attrs_->emplace(attr_name_, v); } void operator()(const std::string& v) const { attrs_->emplace(attr_name_, v); } @@ -134,6 +135,7 @@ struct ConstantOpAttrVisitor { platform::errors::InvalidArgument("Constant value must be a vector")) void operator()(int v) const { RAISE_ERROR; } void operator()(float v) const { RAISE_ERROR; } + void operator()(double v) const { RAISE_ERROR; } void operator()(const std::string& v) const { RAISE_ERROR; } void operator()(const std::vector& v) const { RAISE_ERROR; } void operator()(bool v) const { RAISE_ERROR; } -- GitLab