Skip to content

Commit f1834d9

Browse files
committed
feat: update rules for absolute class name references
1 parent 04a2112 commit f1834d9

File tree

2 files changed

+17
-9
lines changed

2 files changed

+17
-9
lines changed

CHANGELOG.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,13 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
2121
### Security
2222

2323

24+
## [1.2.0] - 2020-09-05
25+
26+
### Added
27+
28+
* Revised rules for absolute class name references
29+
30+
2431
## [1.1.2] - 2020-08-28
2532

2633
### Fixed
@@ -71,7 +78,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
7178
* Initial release of Ramsey coding standard
7279

7380

74-
[Unreleased]: https://github.com/ramsey/coding-standard/compare/1.1.2...HEAD
81+
[Unreleased]: https://github.com/ramsey/coding-standard/compare/1.2.0...HEAD
82+
[1.2.0]: https://github.com/ramsey/coding-standard/compare/1.1.2...1.2.0
7583
[1.1.2]: https://github.com/ramsey/coding-standard/compare/1.1.1...1.1.2
7684
[1.1.1]: https://github.com/ramsey/coding-standard/compare/1.1.0...1.1.1
7785
[1.1.0]: https://github.com/ramsey/coding-standard/compare/1.0.3...1.1.0

src/Ramsey/ruleset.xml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -239,19 +239,19 @@
239239
<!-- Forbid multiple use statements on same line -->
240240
<rule ref="SlevomatCodingStandard.Namespaces.MultipleUsesPerLine"/>
241241

242-
<!-- Forbid using absolute class name references -->
242+
<!-- Forbid using absolute class name references (except global ones) -->
243243
<rule ref="SlevomatCodingStandard.Namespaces.ReferenceUsedNamesOnly">
244244
<properties>
245245
<property name="allowFallbackGlobalConstants" value="false"/>
246+
<property name="allowFallbackGlobalFunctions" value="false"/>
247+
<property name="allowFullyQualifiedGlobalClasses" value="false"/>
246248
<property name="allowFullyQualifiedGlobalConstants" value="false"/>
247249
<property name="allowFullyQualifiedGlobalFunctions" value="false"/>
248-
<property name="allowFullyQualifiedExceptions" value="true"/>
249-
<property name="allowPartialUses" value="false"/>
250-
<property name="fullyQualifiedKeywords" type="array">
251-
<element value="T_EXTENDS"/>
252-
<element value="T_IMPLEMENTS"/>
253-
<element value="T_USE"/>
254-
</property>
250+
<property name="allowFullyQualifiedNameForCollidingClasses" value="true"/>
251+
<property name="allowFullyQualifiedNameForCollidingConstants" value="true"/>
252+
<property name="allowFullyQualifiedNameForCollidingFunctions" value="true"/>
253+
<property name="allowPartialUses" value="true"/>
254+
<property name="searchAnnotations" value="true"/>
255255
</properties>
256256
</rule>
257257

0 commit comments

Comments
 (0)