-
ap@webkit.org authored
<rdar://problem/5934376> REGRESSION: A script fails because of a straw BOM character in it. <https://bugs.webkit.org/show_bug.cgi?id=4931> Unicode format characters (Cf) should be removed from JavaScript source Of all Cf characters, we are only removing BOM, because this is what Firefox trunk has settled upon, after extensive discussion and investigation. Based on Darin's work on this bug. Test: fast/js/removing-Cf-characters.html * kjs/lexer.cpp: (KJS::Lexer::setCode): Tweak formatting. Use a call to shift(4) to read in the first characters, instead of having special case code here. (KJS::Lexer::shift): Add a loop when reading a character to skip BOM characters. git-svn-id: http://svn.webkit.org/repository/webkit/trunk@33443 268f45cc-cd09-0410-ab3c-d52691b4dbfc
53901ad3