'Determines whether an expression is safely escaped, even though it is
using the expression syntax that doesn\'t itself escape (i.e. <%= ).
In some cases it is ok to not use the Underscore.js template escape
(i.e. <%- ) because the escaping is happening inside the expression.
Safe examples::
<%= HtmlUtils.ensureHtml(message) %>
<%= _.escape(message) %>
Arguments:
expression: The Expression being checked.
Returns:
True if the Expression has been safely escaped, and False otherwise.'

def _is_safe_unescaped_expression(self, expression):

    if expression.expression_inner.startswith('HtmlUtils.'):
        return True
    if expression.expression_inner.startswith('_.escape('):
        return True
    return False
