Passed
Pull Request — master (#156)
by Alex
04:11 queued 41s
created
src/Library/EdmValueTerm.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@
 block discarded – undo
37 37
      */
38 38
     public function __construct(string $namespaceName, string $name, $type)
39 39
     {
40
-        $type = ($type instanceof PrimitiveTypeKind) ? EdmCoreModel::getInstance()->getPrimitive($type, true): $type;
40
+        $type = ($type instanceof PrimitiveTypeKind) ? EdmCoreModel::getInstance()->getPrimitive($type, true) : $type;
41 41
         assert($type instanceof ITypeReference);
42 42
         parent::__construct($name);
43 43
         $this->type          = $type;
Please login to merge, or discard this patch.
src/Util/XmlCharType.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -330,9 +330,9 @@
 block discarded – undo
330 330
     private static function setProperties(string $ranges, int $value): void
331 331
     {
332 332
         assert(mb_strlen($ranges, 'UTF-8') % 2 === 0);
333
-        for ($p = 0; $p < mb_strlen($ranges, 'UTF-8'); $p +=2) {
333
+        for ($p = 0; $p < mb_strlen($ranges, 'UTF-8'); $p += 2) {
334 334
             $str1 = mb_substr($ranges, $p, 1, 'UTF-8');
335
-            $str2 = mb_substr($ranges, $p+1, 1, 'UTF-8');
335
+            $str2 = mb_substr($ranges, $p + 1, 1, 'UTF-8');
336 336
             for ($i = mb_ord($str1),
337 337
                  $last = mb_ord($str2); $i <= $last; $i++) {
338 338
                 if (!isset(self::$s_CharProperties[$i])) {
Please login to merge, or discard this patch.
src/Util/ExpressionTypeChecker.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -204,7 +204,7 @@  discard block
 block discarded – undo
204 204
                 // If we don't have the applied function we just assume that it will work.
205 205
                 $discoveredErrors = [];
206 206
                 return true;
207
-            case ExpressionKind::If():
207
+            case ExpressionKind::If ():
208 208
                 assert($expression instanceof IIfExpression);
209 209
                 return self::tryAssertIfAsType($expression, $type, $context, $matchExactly, $discoveredErrors);
210 210
             case ExpressionKind::IsType():
@@ -306,7 +306,7 @@  discard block
 block discarded – undo
306 306
         iterable &$discoveredErrors
307 307
     ): bool {
308 308
         if (!$type->isPrimitive()) {
309
-            $discoveredErrors =  [
309
+            $discoveredErrors = [
310 310
                 new EdmError(
311 311
                     $expression->location(),
312 312
                     EdmErrorCode::PrimitiveConstantExpressionNotValidForNonPrimitiveType(),
@@ -770,7 +770,7 @@  discard block
 block discarded – undo
770 770
                 return self::tryAssertIntegerConstantInRange(
771 771
                     $expression,
772 772
                     (int)-9223372036854775808,
773
-                    (int)999999999999,
773
+                    (int) 999999999999,
774 774
                     $discoveredErrors
775 775
                 );
776 776
             case PrimitiveTypeKind::Int32():
@@ -802,7 +802,7 @@  discard block
 block discarded – undo
802 802
                     $discoveredErrors
803 803
                 );
804 804
             default:
805
-                $discoveredErrors =  [
805
+                $discoveredErrors = [
806 806
                     new EdmError(
807 807
                         $expression->location(),
808 808
                         EdmErrorCode::ExpressionPrimitiveKindNotValidForAssertedType(),
@@ -926,7 +926,7 @@  discard block
 block discarded – undo
926 926
 
927 927
             if ($expressionType->getTypeKind()->isPrimitive() && $assertedType->getTypeKind()->isPrimitive()) {
928 928
                 $primitiveExpressionType = $expressionType;
929
-                $primitiveAssertedType   = $assertedType ;
929
+                $primitiveAssertedType   = $assertedType;
930 930
                 assert($primitiveExpressionType instanceof IPrimitiveType);
931 931
                 assert($primitiveAssertedType instanceof IPrimitiveType);
932 932
                 if (!self::promotesTo(
Please login to merge, or discard this patch.
IEdmElement/ElementDirectValueAnnotationFullNameMustBeUnique.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -26,7 +26,7 @@
 block discarded – undo
26 26
         foreach ($context->getModel()->getDirectValueAnnotationsManager()->getDirectValueAnnotations($item) as $annotation) {
27 27
             assert($annotation instanceof IDirectValueAnnotation);
28 28
             EdmUtil::checkArgumentNull($annotation->location(), 'annotation->Location');
29
-            if (! $annotationNameSet->add($annotation->getNamespaceUri() . ':' . $annotation->getName())) {
29
+            if (!$annotationNameSet->add($annotation->getNamespaceUri() . ':' . $annotation->getName())) {
30 30
                 EdmUtil::checkArgumentNull($annotation->location(), 'annotation->Location');
31 31
                 $context->addError(
32 32
                     $annotation->location(),
Please login to merge, or discard this patch.
src/Edm/Validation/Internal/InterfaceValidator/VisitorOfIStructuredType.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@
 block discarded – undo
28 28
         );
29 29
 
30 30
         if (null !== $type->getBaseType()) {
31
-            $visitedTypes   = new HashSetInternal();
31
+            $visitedTypes = new HashSetInternal();
32 32
             $visitedTypes->add($type);
33 33
             /** @var IStructuredType|null $currentBaseType */
34 34
             for ($currentBaseType = $type->getBaseType(); null !== $currentBaseType; $currentBaseType = $currentBaseType->getBaseType()
Please login to merge, or discard this patch.