Cleanup: remove check for non-annotation properties in classes

This was added to assist upgrading scripts to Blender 2.8x,
now 2.9x is released there is no need to keep this block.
This commit is contained in:
2021-02-18 15:45:08 +11:00
parent 9df9269173
commit afa5da9ce0

View File

@@ -7977,31 +7977,6 @@ static int pyrna_deferred_register_props(StructRNA *srna, PyObject *class_dict)
}
}
if (ret == 0) {
/* This block can be removed once 2.8x is released and annotations are in use. */
bool has_warning = false;
while (PyDict_Next(class_dict, &pos, &key, &item)) {
if (pyrna_is_deferred_prop(item)) {
if (!has_warning) {
printf(
"Warning: class %.200s "
"contains a property which should be an annotation!\n",
RNA_struct_identifier(srna));
PyC_LineSpit();
has_warning = true;
}
printf(" assign as a type annotation: %.200s.%.200s\n",
RNA_struct_identifier(srna),
PyUnicode_AsUTF8(key));
}
ret = deferred_register_prop(srna, key, item);
if (ret != 0) {
break;
}
}
}
return ret;
}