Index: Lib/tokenize.py =================================================================== --- Lib/tokenize.py (révision 66703) +++ Lib/tokenize.py (copie de travail) @@ -26,7 +26,7 @@ import re, string, sys from token import * -from codecs import lookup +from codecs import lookup, BOM_UTF8 from itertools import chain, repeat cookie_re = re.compile("coding[:=]\s*([-\w.]+)") @@ -255,7 +255,7 @@ If no encoding is specified, then the default of 'utf-8' will be returned. """ - utf8_bom = b'\xef\xbb\xbf' + utf8_bom = BOM_UTF8 bom_found = False encoding = None def read_or_stop():