On Mon, Jun 24, 2013 at 7:40 PM, Mike Samuel <
mikes...@gmail.com> wrote:
> Yeah.
>
> I'm not trying to justify the inscrutability of the error message, but
> that error message happens because it starts in JS as indicated by
> "{stateJS" and then sees
>
> <option>{{.Name }}</option>
>
> which could be a sequence of valid but nonsensical JS tokens as in the
> explicitly parenthesized
>
> ((1 < option) > "name") < /option>/
>
> and ends inside a regular expression as indicated by "{stateJSRegexp"
> because only one slash has been seen.
>
This is brilliant. I knew html/template uses context to safely escape
JavaScript. Thank you for your great work.