When implementing the ERC721 contract standard, how strictly does one have to stick to the naming conventions of the method signatures - as spelled out by the standard?

Take for example the ownerOf function. The standard spells it out as follows:

function ownerOf(uint256 _tokenId) external view returns (address);

But what happens if I change the argument names when I implement this function in my contract? For example:

function ownerOf(uint256 _creatureID) external view returns (addressOfOwner);

So instead of _tokenId I have _creatureID and instead of address I have addressOfOwner?

Does that negate the conformity? Will other platforms not be able to recognize and work with my contract because I made these changes? Or is it only the function's actual name - ownerOf - that matters?


Parameter names are not included in the specification.

You can confirm it is working correctly by using the interface included in the EIP and having your contract subclass (is) that.

But for address, that is a return type, not a name. So you might consider address addressOfOwner.

  • 1
    got it - makes sense. Thank you!
    – Mark55
    May 8 at 22:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.