When the value of asp.default.language is 2 ("assume scripts are ASP"),1 line comments are not terminated inside legacy-style code blocks (<%...%>), e.g.
Text
<html>
<% 'comment %>
</html>
Styles
{1}<html>{0}
{15}<%{81} {82}'comment %>{81}
</{86}html{81}>
The same occurs within ASP string-interpolation tags, data-binding tags, and so-called expression builders.
The exceptions are directive expressions and server-side comments, apparently because they activate states which don't permit nested styles; SCE_H_ASPAT (16) in the former's case:
{1}<html>{0}
{15}<%@{16} 'comment {15}%>{0}
{1}</html>{0}
SCE_H_XCCOMMENT (20) in the latter:
{1}<html>{0}
{15}<%--{20} 'comment --{15}%>{0}
{1}</html>{0}
When the value of
asp.default.languageis 2 ("assume scripts are ASP"),1 line comments are not terminated inside legacy-style code blocks (<%...%>), e.g.Text
Styles
The same occurs within ASP string-interpolation tags, data-binding tags, and so-called expression builders.
The exceptions are directive expressions and server-side comments, apparently because they activate states which don't permit nested styles;
SCE_H_ASPAT(16) in the former's case:SCE_H_XCCOMMENT(20) in the latter:Footnotes
Given the default option value ("assume scripts are JS"), line comments are (correctly) taken for single-quoted JavaScript strings. ↩