Operator arguments - Identification if object names are not unique? A lot operators use StringPropertys to reference objects by name. This works well for ID datablocks - no duplicate names allowed (although there can be issues with linked datablocks).

But not all objects are of type ID datablock, and unique names may not be enforced. Related operators may take a string for indentification however. Thus you may not act upon the right object.

If names aren't unique, one could use an integer to reference by index. But I wonder if there are any operators, which actually take a pointer to the right object (in C)? Like:

ot-&gt;prop = RNA_def_pointer(...);


Is it even possible to use pointers as operator properties? It would mean that python couldn't make any use of it, if I'm not mistaken (or could one pass a python object, and have C code figure out the pointer?).
Operators should never have pointer properties and as far as I know there aren't any that do.

Such pointers would not be valid after deleting objects or after undo/redo steps, which would give problems in the operator history stack when repeating operators for example.

Operators that take datablock names should usually be avoided for python scripting. It's better to edit the data directly than going through operators when possible, there's probably only a handful of cases where you need to do this.