diff --git a/paddle/fluid/framework/operator.cc b/paddle/fluid/framework/operator.cc index 4ccef3105c6c1724f0b767d657fa39ac5a6ce266..2f418f728fb6a3fe2e393f5b62d71537e97f1a35 100644 --- a/paddle/fluid/framework/operator.cc +++ b/paddle/fluid/framework/operator.cc @@ -625,8 +625,7 @@ class RuntimeInferShapeContext : public InferShapeContext { Variable* out_var = out_it->second[j]; PADDLE_ENFORCE(in_var->Type() == out_var->Type(), - "The type of %s and %s is not the same.", in_var->Type(), - out_var->Type()); + "The type of %s and %s is not the same.", in, out); if (in_var->IsType()) { auto& in_sele_rows = in_var->Get();