p=p.replace(/(\s)([^<]+)$/g, function(s,p1,p2) { p2=p2.replace(/(=)(\s*[^"'][^\s]*)(\s|$)/g,'$1<span class=attribute-value>$2</span>$3'); 
p=p.replace(/(\s)([^<]+)$/g, function(s,p1,p2) { p2=p2.replace(/(=)(\s*[^"'][^\s]*)(\s|$)/g,'$1<span class=attribute-value>$2</span>$3'); 
function formatHTML(h){  // a replace function used in the succeeding lines -  function S(s)  {    return s.replace(/</g,'&lt;').replace(/>/g,'&gt;');  }  h+='\n';  h=h.replace(/&([^\s]+;)/g,'&lt;&amp;$1&gt;');  h=h.replace(new RegExp('<!-'+'-[\\s\\S]*-'+'->','g'), S);  h=h.replace(/"[^"]*"/g,S);  h=h.replace(/'[^']*'/g,S);  h=h.replace(/<([^>]*)>/g,              function(s,p)              {                if(s.match(/!doctype/i))                  return'<span class=doctype>&lt;' + p + '&gt;</span>';                p=p.replace(/\\'/g,'\\&#39;').replace(/\\"/g,'\\&#34;').replace(/^\s/,'');                p=p.replace(/(\s)([^<]+)$/g,                            function(s,p1,p2)                            {                              p2=p2.replace(/(=)(\s*[^"'][^\s]*)(\s|$)/g,'$1<span class=attribute-value>$2</span>$3');                              p2=p2.replace(/("[^"]*")/g,'<span class=attribute-value>$1</span>');                              p2=p2.replace(/('[^']*')/g,'<span class=attribute-value>$1</span>');                              return p1 + '<span class=attribute-name>'+p2+'</span>';                            }                           )                return'&lt;<span class=' + (s.match(/<\s*\//)?'end-tag':'start-tag') + '>' + p + '</span>&gt;';              }             )  h=h.replace(/&lt;(&[^\s]+;)&gt;/g,'<span class=entity>$1</span>');  h=h.replace(/(&lt;!--[\s\S]*--&gt;)/g,'<span class=comment>$1</span>');  numer=1;  h=h.replace(/(.*\n)/g,              function(s,p)              {                return (numer++) +'. ' + p;              }             )  return'<span class=text>' + h + '</span>';}
5872	/local1/tlutelli/issta_data/temp/all_js/javascript/2007_temp/2007/5872/3703c3c05f398a63e55992f7687ef65273b26d6a/regress-209067.js/buggy/js/tests/ecma_3/RegExp/regress-209067.js