[Bug 3648] The - -) is interpreted as - -> in javascript and breaks check

http://www.w3.org/Bugs/Public/show_bug.cgi?id=3648

           Summary: The - -) is interpreted as - -> in javascript and breaks
                    check
           Product: Validator
           Version: HEAD
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: critical
          Priority: P2
         Component: check
        AssignedTo: link@pobox.com
        ReportedBy: phil@thomassigny.org
         QAContact: www-validator-cvs@w3.org


here is a *very* simple example showing the bug.
It happens on XHTML 1.0 transitional, i did not tried on other versions.
the --) into the javascript is interpreted as the end tag for comment instead
of --> really at the end of the javascript, which break any html page that
contains a "--" operator followed by a ")"

Thanks

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html>
<head>
  <title>Some title</title>
</head>
<body>
<script type="text/javascript">
<!--
for(i = to_fill.options.length; i >= 0; i--)
  alert(i);
// -->
</script>
</body>
</html>

Received on Friday, 1 September 2006 18:01:18 UTC