Completed
Push — master ( 042fd9...556fe8 )
by Christophe
01:56
created
src/BitArray/BitArray.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -121,7 +121,7 @@
 block discarded – undo
121 121
 	 *
122 122
 	 * @throws  \RuntimeException  If the property does not exist
123 123
 	 *
124
-	 * @return  mixed  The value associated to the property
124
+	 * @return  integer  The value associated to the property
125 125
 	 *
126 126
 	 * @since   1.0.0
127 127
 	 */
Please login to merge, or discard this patch.
Braces   +10 added lines, -20 removed lines patch added patch discarded remove patch
@@ -168,8 +168,7 @@  discard block
 block discarded – undo
168 168
 		if ($this->offsetExists($offset))
169 169
 		{
170 170
 			return (bool) (ord($this->data[(int) ($offset / 8)]) & (1 << $offset % 8));
171
-		}
172
-		else
171
+		} else
173 172
 		{
174 173
 			throw new \OutOfRangeException('Argument offset must be a positive integer lesser than the size');
175 174
 		}
@@ -196,13 +195,11 @@  discard block
 block discarded – undo
196 195
 			if ($value)
197 196
 			{
198 197
 				$this->data[$index] = chr(ord($this->data[$index]) | (1 << $offset % 8));
199
-			}
200
-			else
198
+			} else
201 199
 			{
202 200
 				$this->data[$index] = chr(ord($this->data[$index]) & ~(1 << $offset % 8));
203 201
 			}
204
-		}
205
-		else
202
+		} else
206 203
 		{
207 204
 			throw new \OutOfRangeException('Argument index must be a positive integer lesser than the size');
208 205
 		}
@@ -320,8 +317,7 @@  discard block
 block discarded – undo
320 317
 			{
321 318
 				$this[$i + $index] = $bits[$i + $offset];
322 319
 			}
323
-		}
324
-		else
320
+		} else
325 321
 		{
326 322
 			for ($i = $size - 1; $i >= 0; $i--)
327 323
 			{
@@ -389,8 +385,7 @@  discard block
 block discarded – undo
389 385
 			{
390 386
 				$offset = 0;
391 387
 			}
392
-		}
393
-		elseif ($offset > $this->size)
388
+		} elseif ($offset > $this->size)
394 389
 		{
395 390
 			$offset = $this->size;
396 391
 		}
@@ -415,8 +410,7 @@  discard block
 block discarded – undo
415 410
 		if ($size === null)
416 411
 		{
417 412
 			$size = $this->size - $offset;
418
-		}
419
-		else
413
+		} else
420 414
 		{
421 415
 			$size = (int) $size;
422 416
 
@@ -428,8 +422,7 @@  discard block
 block discarded – undo
428 422
 				{
429 423
 					$size = 0;
430 424
 				}
431
-			}
432
-			elseif ($size > $this->size - $offset)
425
+			} elseif ($size > $this->size - $offset)
433 426
 			{
434 427
 				$size = $this->size - $offset;
435 428
 			}
@@ -633,8 +626,7 @@  discard block
 block discarded – undo
633 626
 			}
634 627
 
635 628
 			return $this;
636
-		}
637
-		else
629
+		} else
638 630
 		{
639 631
 			throw new \InvalidArgumentException('Argument must be of equal size');
640 632
 		}
@@ -663,8 +655,7 @@  discard block
 block discarded – undo
663 655
 			}
664 656
 
665 657
 			return $this;
666
-		}
667
-		else
658
+		} else
668 659
 		{
669 660
 			throw new \InvalidArgumentException('Argument must be of equal size');
670 661
 		}
@@ -693,8 +684,7 @@  discard block
 block discarded – undo
693 684
 			}
694 685
 
695 686
 			return $this;
696
-		}
697
-		else
687
+		} else
698 688
 		{
699 689
 			throw new \InvalidArgumentException('Argument must be of equal size');
700 690
 		}
Please login to merge, or discard this patch.