hot fix for print

This commit is contained in:
TFBunny 2021-03-18 13:32:04 -04:00
parent e789642e9a
commit 32e86f4166
1 changed files with 4 additions and 0 deletions

View File

@ -67,6 +67,10 @@ bool GetOptList(const std::vector<AnfNodePtr> &node_list, std::vector<AnfNodePtr
continue;
}
auto value_node = current_node->cast<ValueNodePtr>()->value();
// not a string
if (value_node->type() == nullptr) {
continue;
}
if (value_node->type()->generic_type_id() == kObjectTypeString) {
auto current_string_value = GetValue<std::string>(value_node);
string_pos.push_back(i);