Skip to content
This repository was archived by the owner on Jan 29, 2020. It is now read-only.

Commit c2a11bb

Browse files
committed
Trying to fix a platform issue with windows line ending
Uniformazing the line ending in the project to avoid issue with windows. Fix #45 and Fix #39
1 parent 202a97d commit c2a11bb

File tree

7 files changed

+11
-11
lines changed

7 files changed

+11
-11
lines changed

src/Generator/MethodGenerator.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ protected static function clearBodyIndention($body)
9393
return $body;
9494
}
9595

96-
$lines = explode(PHP_EOL, $body);
96+
$lines = explode("\n", $body);
9797

9898
$indention = str_replace(trim($lines[1]), '', $lines[1]);
9999

@@ -103,7 +103,7 @@ protected static function clearBodyIndention($body)
103103
}
104104
}
105105

106-
$body = implode(PHP_EOL, $lines);
106+
$body = implode("\n", $lines);
107107

108108
return $body;
109109
}

src/Reflection/DocBlock/Tag/AuthorTag.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,6 @@ public function getAuthorEmail()
6969

7070
public function __toString()
7171
{
72-
return 'DocBlock Tag [ * @' . $this->getName() . ' ]' . PHP_EOL;
72+
return 'DocBlock Tag [ * @' . $this->getName() . ' ]' . "\n";
7373
}
7474
}

src/Reflection/DocBlock/Tag/GenericTag.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ public function returnValue($position)
9595
*/
9696
public function __toString()
9797
{
98-
return 'DocBlock Tag [ * @' . $this->name . ' ]' . PHP_EOL;
98+
return 'DocBlock Tag [ * @' . $this->name . ' ]' . "\n";
9999
}
100100

101101
/**

src/Reflection/DocBlock/Tag/LicenseTag.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,6 @@ public function getLicenseName()
6969

7070
public function __toString()
7171
{
72-
return 'DocBlock Tag [ * @' . $this->getName() . ' ]' . PHP_EOL;
72+
return 'DocBlock Tag [ * @' . $this->getName() . ' ]' . "\n";
7373
}
7474
}

src/Reflection/DocBlock/Tag/MethodTag.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,6 @@ public function isStatic()
117117

118118
public function __toString()
119119
{
120-
return 'DocBlock Tag [ * @' . $this->getName() . ' ]' . PHP_EOL;
120+
return 'DocBlock Tag [ * @' . $this->getName() . ' ]' . "\n";
121121
}
122122
}

src/Reflection/DocBlock/Tag/PropertyTag.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,6 @@ public function getDescription()
9595

9696
public function __toString()
9797
{
98-
return 'DocBlock Tag [ * @' . $this->getName() . ' ]' . PHP_EOL;
98+
return 'DocBlock Tag [ * @' . $this->getName() . ' ]' . "\n";
9999
}
100100
}

src/Reflection/DocBlockReflection.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -271,15 +271,15 @@ protected function reflect()
271271
*/
272272
public function toString()
273273
{
274-
$str = "DocBlock [ /* DocBlock */ ] {" . PHP_EOL . PHP_EOL;
275-
$str .= " - Tags [" . count($this->tags) . "] {" . PHP_EOL;
274+
$str = "DocBlock [ /* DocBlock */ ] {" . "\n" . "\n";
275+
$str .= " - Tags [" . count($this->tags) . "] {" . "\n";
276276

277277
foreach ($this->tags as $tag) {
278278
$str .= " " . $tag;
279279
}
280280

281-
$str .= " }" . PHP_EOL;
282-
$str .= "}" . PHP_EOL;
281+
$str .= " }" . "\n";
282+
$str .= "}" . "\n";
283283

284284
return $str;
285285
}

0 commit comments

Comments
 (0)