Propagated class __Const attribute through to member variables
commit1e1f238f9bdc561a4b9c023ac7ef3f0ff3770445
authorVassil Mladenov <vmladenov@fb.com>
Mon, 4 Dec 2017 22:26:09 +0000 (4 14:26 -0800)
committerHhvm Bot <hhvm-bot@users.noreply.github.com>
Mon, 4 Dec 2017 22:36:29 +0000 (4 14:36 -0800)
treee2b6fa5f5cfea280d80f5b2e9a45bf44d030be50
parent2c8befe8d6c1b58d52653003b09a774e03c91622
Propagated class __Const attribute through to member variables

Summary: When a class is marked __Const, its instance members will get the __Const property as well. Instance members are permitted to have redundant __Const attributes.

Reviewed By: jamesjwu

Differential Revision: D6392281

fbshipit-source-id: f63bcef1d527e93dcf1d6a01a36cbfb8ed2782dc
hphp/hack/src/naming/naming.ml
hphp/hack/test/typecheck/const_attribute/class_const_attribute.php [new file with mode: 0644]
hphp/hack/test/typecheck/const_attribute/class_const_attribute.php.exp [new file with mode: 0644]
hphp/hack/test/typecheck/const_attribute/class_const_attribute_outside_class.php [new file with mode: 0644]
hphp/hack/test/typecheck/const_attribute/class_const_attribute_outside_class.php.exp [new file with mode: 0644]
hphp/hack/test/typecheck/const_attribute/trait_const_attribute.php [new file with mode: 0644]
hphp/hack/test/typecheck/const_attribute/trait_const_attribute.php.exp [new file with mode: 0644]