protected function compileTag(Tag $tag)
{
$selfClosing = (in_array(strtolower($tag->name), $this->selfClosing) || $tag->selfClosing) && !$this->xml;
$this->visitTagAttributes($tag, !$tag->keepWhiteSpaces() && $this->prettyprint, !$selfClosing || $this->terse ? '>' : ' />');
if (!$selfClosing) {
$this->visitTagContents($tag);
$this->buffer('</' . $tag->name . '>', $tag->keepWhiteSpaces() ? false : null);
}
}