diff --git a/paddle/fluid/platform/device/ipu/ipu_compiler.cc b/paddle/fluid/platform/device/ipu/ipu_compiler.cc index 22b8b67fa64ad1caeb4d40d55450808f8d74a536..7eaf25f5dfdcd17decf2b5ca673fa27d6db5592f 100644 --- a/paddle/fluid/platform/device/ipu/ipu_compiler.cc +++ b/paddle/fluid/platform/device/ipu/ipu_compiler.cc @@ -80,6 +80,16 @@ struct CustomOpAttrVisitor { "Unsupported calling method for `paddle::blank` type when extracting " "custom operator attributes.")); } + void operator()(framework::VarDesc*) const { + PADDLE_THROW(platform::errors::Unavailable( + "Unsupported calling method for `VarDesc*` type when extracting " + "custom operator attributes.")); + } + void operator()(const std::vector&) const { + PADDLE_THROW(platform::errors::Unavailable( + "Unsupported calling method for `std::vector` " + "type when extracting custom operator attributes.")); + } }; struct ConstantOpAttrVisitor { @@ -131,6 +141,10 @@ struct ConstantOpAttrVisitor { void operator()(const std::vector& v) const { RAISE_ERROR; } void operator()(int64_t v) const { RAISE_ERROR; } void operator()(paddle::blank) const { RAISE_ERROR; } + void operator()(framework::VarDesc*) const { RAISE_ERROR; } + void operator()(const std::vector&) const { + RAISE_ERROR; + } #undef RAISE_ERROR };