Leafo\ScssPhp\Compiler::pushEnv PHP Method

pushEnv() protected method

Push environment
protected pushEnv ( Leafo\ScssPhp\Block $block = null ) : Leafo\ScssPhp\Compiler\Environment
$block Leafo\ScssPhp\Block
return Leafo\ScssPhp\Compiler\Environment
    protected function pushEnv(Block $block = null)
    {
        $env = new Environment();
        $env->parent = $this->env;
        $env->store = [];
        $env->block = $block;
        $env->depth = isset($this->env->depth) ? $this->env->depth + 1 : 0;
        $this->env = $env;
        return $env;
    }
Compiler