rfc:shorter_attribute_syntax

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
rfc:shorter_attribute_syntax [2020/06/17 21:47]
theodorejb Prepare voting choices
rfc:shorter_attribute_syntax [2020/08/12 15:56] (current)
theodorejb Update nested syntax for #[] - I think this was a relic of the idea to strip all leading hashes
Line 2: Line 2:
   * Date: 2020-06-03   * Date: 2020-06-03
   * Author: Theodore Brown <theodorejb@outlook.com>, Martin Schröder   * Author: Theodore Brown <theodorejb@outlook.com>, Martin Schröder
-  * Status: Under Discussion+  * Status: Implemented
   * Discussion: https://externals.io/message/110355   * Discussion: https://externals.io/message/110355
   * Target Version: PHP 8.0   * Target Version: PHP 8.0
-  * Implementation for ''@@'': https://github.com/koolkode/php-src/pull/+  * Implementation: https://github.com/php/php-src/pull/5796
-  * Implementation for ''#[]'': https://github.com/koolkode/php-src/pull/5+
  
 ===== Introduction ===== ===== Introduction =====
Line 199: Line 198:
     #[JoinTable(     #[JoinTable(
         "User_Group",         "User_Group",
-        #JoinColumn("User_id", "id"), +        #[JoinColumn("User_id", "id")]
-        #JoinColumn("Group_id", "id"),+        #[JoinColumn("Group_id", "id")],
     )]     )]
     private $groups;     private $groups;
Line 299: Line 298:
 Attributes can still be applied to all the same places outlined in the [[https://wiki.php.net/rfc/attributes_v2|Attributes v2]] RFC. Non-syntactical attribute functionality also remains unchanged (e.g. the reflection API). Attributes can still be applied to all the same places outlined in the [[https://wiki.php.net/rfc/attributes_v2|Attributes v2]] RFC. Non-syntactical attribute functionality also remains unchanged (e.g. the reflection API).
  
-Finally, this proposal does not conflict with the [[https://wiki.php.net/rfc/attribute_amendments|Attribute Amendments]] RFC, with the exception that if the shorter syntax is accepted, it will supersede the syntax for grouped attributes.+Finally, this proposal does not conflict with the [[https://wiki.php.net/rfc/attribute_amendments|Attribute Amendments]] RFC, with the exception that if the ''@@'' syntax is accepted, it will supersede the syntax for grouped attributes.
  
  
Line 311: Line 310:
 ===== Vote ===== ===== Vote =====
  
-Voting starts on 2020-06-17 and will end on 2020-07-01.+Voting started on 2020-06-17 and ended on 2020-07-01.
  
 ==== Primary vote ==== ==== Primary vote ====
Line 326: Line 325:
 === First choice === === First choice ===
  
-<doodle title="Attribute syntax 1st choice" auth="theodorejb" voteType="single" closed="true">+<doodle title="Attribute syntax choice #1" auth="theodorejb" voteType="single" closed="true">
    * @@    * @@
    * #[]    * #[]
Line 334: Line 333:
 === Second choice === === Second choice ===
  
-<doodle title="Attribute syntax 2nd choice" auth="theodorejb" voteType="single" closed="true">+<doodle title="Attribute syntax choice #2" auth="theodorejb" voteType="single" closed="true">
    * @@    * @@
    * #[]    * #[]
Line 342: Line 341:
 === Third choice === === Third choice ===
  
-<doodle title="Attribute syntax 3rd choice" auth="theodorejb" voteType="single" closed="true">+<doodle title="Attribute syntax choice #3" auth="theodorejb" voteType="single" closed="true">
    * @@    * @@
    * #[]    * #[]
rfc/shorter_attribute_syntax.1592430427.txt.gz · Last modified: 2020/06/17 21:47 by theodorejb