Re: Re: PHP Annotations RFC + Patch
| From: | Stas Malyshev | Date: | Wed, 08 Sep 2010 18:16:53 +0000 |
| Subject: | Re: Re: PHP Annotations RFC + Patch | ||
| References: | 1 2 3 4 5 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-49588@lists.php.net to get a copy of this message | ||
Hi!
I'm getting a feeling we are developing language inside language here. We rejected [] syntax for arrays because it makes the intent unclear. I'd say if that's unclear [Validation([Email(checkMX = true)])] is super-unclear - what exactly is supposed to happen there? It is very non-obvious. I think it needs to be radically simplified. I understand that people that write ORMs etc. want their work to be easier, but I don't think turning PHP into a mesh of random brackets and words worth it. If we can't find a model that is easy to comprehend, ORMs would have to use XML or other outside-of-syntax means. -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227[JoinTable(name="users_phonenumbers", joinColumns=array( [JoinColumn(name="user_id", referencedColumnName="id")] ), inverseJoinColumns=array( [JoinColumn(name="phonenumber_id", referencedColumnName="id",unique=true)]))][Validation([Email(checkMX = true)])]