Skip to content

Commit

Permalink
[CLEANUP] Rector: Add missing return type declaration based on parent…
Browse files Browse the repository at this point in the history
… class method (MyIntervals#606)

This applies the rule AddReturnTypeDeclarationBasedOnParentClassMethodRector. For
Details see:
https://github.com/rectorphp/rector/blob/main/docs/rector_rules_overview.md#addreturntypedeclarationbasedonparentclassmethodrector

Signed-off-by: Daniel Ziegenberg <[email protected]>
  • Loading branch information
ziegenberg authored Jun 24, 2024
1 parent 1908a05 commit cc53c85
Show file tree
Hide file tree
Showing 19 changed files with 19 additions and 75 deletions.
5 changes: 1 addition & 4 deletions src/CSSList/AtRuleBlockList.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,7 @@ public function atRuleArgs()
return $this->sArgs;
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down
5 changes: 1 addition & 4 deletions src/CSSList/CSSList.php
Original file line number Diff line number Diff line change
Expand Up @@ -394,10 +394,7 @@ public function removeDeclarationBlockBySelector($mSelector, $bRemoveAll = false
}
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down
5 changes: 1 addition & 4 deletions src/CSSList/KeyFrame.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,7 @@ public function getAnimationName()
return $this->animationName;
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down
5 changes: 1 addition & 4 deletions src/Comment/Comment.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,7 @@ public function setComment($sComment): void
$this->sComment = $sComment;
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down
5 changes: 1 addition & 4 deletions src/Property/CSSNamespace.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,7 @@ public function getLineNo()
return $this->iLineNo;
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down
5 changes: 1 addition & 4 deletions src/Property/Charset.php
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,7 @@ public function getCharset()
return $this->oCharset->getString();
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down
5 changes: 1 addition & 4 deletions src/Property/Import.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,7 @@ public function getLocation()
return $this->oLocation;
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down
5 changes: 1 addition & 4 deletions src/Property/Selector.php
Original file line number Diff line number Diff line change
Expand Up @@ -113,10 +113,7 @@ public function setSelector($sSelector): void
$this->iSpecificity = null;
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->getSelector();
}
Expand Down
5 changes: 1 addition & 4 deletions src/Rule/Rule.php
Original file line number Diff line number Diff line change
Expand Up @@ -247,10 +247,7 @@ public function getIsImportant()
return $this->bIsImportant;
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down
5 changes: 1 addition & 4 deletions src/RuleSet/AtRuleSet.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,7 @@ public function atRuleArgs()
return $this->sArgs;
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down
4 changes: 1 addition & 3 deletions src/RuleSet/DeclarationBlock.php
Original file line number Diff line number Diff line change
Expand Up @@ -775,11 +775,9 @@ public function createFontShorthand(): void
}

/**
* @return string
*
* @throws OutputException
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down
5 changes: 1 addition & 4 deletions src/RuleSet/RuleSet.php
Original file line number Diff line number Diff line change
Expand Up @@ -252,10 +252,7 @@ public function removeRule($mRule): void
}
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down
5 changes: 1 addition & 4 deletions src/Value/CSSFunction.php
Original file line number Diff line number Diff line change
Expand Up @@ -96,10 +96,7 @@ public function getArguments()
return $this->aComponents;
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down
5 changes: 1 addition & 4 deletions src/Value/CSSString.php
Original file line number Diff line number Diff line change
Expand Up @@ -86,10 +86,7 @@ public function getString()
return $this->sString;
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down
5 changes: 1 addition & 4 deletions src/Value/Color.php
Original file line number Diff line number Diff line change
Expand Up @@ -144,10 +144,7 @@ public function getColorDescription()
return $this->getName();
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down
5 changes: 1 addition & 4 deletions src/Value/LineName.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,7 @@ public static function parse(ParserState $oParserState): LineName
return new LineName($aNames, $oParserState->currentLine());
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down
5 changes: 1 addition & 4 deletions src/Value/Size.php
Original file line number Diff line number Diff line change
Expand Up @@ -194,10 +194,7 @@ public function isRelative(): bool
return false;
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down
5 changes: 1 addition & 4 deletions src/Value/URL.php
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,7 @@ public function getURL()
return $this->oURL;
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down
5 changes: 1 addition & 4 deletions src/Value/ValueList.php
Original file line number Diff line number Diff line change
Expand Up @@ -77,10 +77,7 @@ public function setListSeparator($sSeparator): void
$this->sSeparator = $sSeparator;
}

/**
* @return string
*/
public function __toString()
public function __toString(): string
{
return $this->render(new OutputFormat());
}
Expand Down

0 comments on commit cc53c85

Please sign in to comment.