Renaming type-hints to something else?

From: Date: Tue, 16 Sep 2014 15:11:03 +0000
Subject: Renaming type-hints to something else?
Groups: php.internals 
Request: Send a blank email to internals+get-77252@lists.php.net to get a copy of this message
Dear list, I've always been bothered by the fact that we call type declarations 'hints', as if they aren't enforced. They have always been enforced and we don't have an option to turn them off. I'm wondering if we want to move away from that name to something else. I have two RFCs already that deal with types and need to know if there would be support for changing it, because that influences internal and external names. Here's an example: the return types RFC creates a struct that is currently called zend_type_decl. This struct is only used for return types at present, but could be unified with arginfo to work with parameter type declarations as well. I'd prefer not to call it zend_type_hint or zend_typehint, because they aren't 'hints'. This also manifests itself to users because of reflection as well. HHVM internally calls them TypeAnnotations, but since we've had RFC proposals about something "annotations" which are something else I'd prefer to stay away from that. Can anyone come up with a better name than hints? Maybe `type declarations? Or should we just stick with hints`? What do you guys think?

« previous php.internals (#77252) next »