Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Compiler.php

function Compiler::outdent

Return value

$this

Throws

\LogicException When trying to outdent too much so the indentation would become negative

File

vendor/twig/twig/src/Compiler.php, line 232

Class

Compiler
@author Fabien Potencier <fabien@symfony.com>

Namespace

Twig

Code

public function outdent(int $step = 1) {
    // can't outdent by more steps than the current indentation level
    if ($this->indentation < $step) {
        throw new \LogicException('Unable to call outdent() as the indentation would become negative.');
    }
    $this->indentation -= $step;
    return $this;
}
RSS feed
Powered by Drupal