 
         ##
 
-        if cached
+        if config.cached
             TEMPLATES[hash] = template
 
         return template

                html += "<![endif]-->"
                return

        for tag in tagsNormal
            compileTag tag, false # don't self close



TEMPLATES = {}

module.exports = (code, config=true)->
    if typeof cached is 'boolean'
        config =
            cached: config || config isnt false

    if typeof code is 'function'
        code = '('+code.toString()+').call(this);'

    if !config.cached || !TEMPLATES[hash = floyd.tools.strings.hash code]

        ##
        html    = null
