From dbb48a7402054ffb883b278d56d0530e9f3b8caf Mon Sep 17 00:00:00 2001 From: Tooru Fujisawa Date: Wed, 28 Jan 2015 13:06:37 +0900 Subject: [PATCH] Bug 1069416 - Part 4: Remove JS_HAS_SYMBOLS support from make_opcode_doc.py. r=Waldo --- js/src/vm/make_opcode_doc.py | 26 ++++---------------------- 1 file changed, 4 insertions(+), 22 deletions(-) diff --git a/js/src/vm/make_opcode_doc.py b/js/src/vm/make_opcode_doc.py index 1a6fce956857..b7c1faf67df8 100755 --- a/js/src/vm/make_opcode_doc.py +++ b/js/src/vm/make_opcode_doc.py @@ -24,8 +24,6 @@ def error(message): def get_xdr_version(dir): subtrahend_pat = re.compile('XDR_BYTECODE_VERSION_SUBTRAHEND\s*=\s*(\d+);', re.S) version_expr_pat = re.compile('XDR_BYTECODE_VERSION\s*=\s*uint32_t\(0xb973c0de\s*-\s*(.+?)\);', re.S) - # FIXME: Bug 1066322 - Enable ES6 symbols in all builds. - bug1066322_pat = re.compile('#ifdef\s+JS_HAS_SYMBOLS\s+\+\s*1*\s+#endif', re.S) with open('{dir}/js/src/vm/Xdr.h'.format(dir=dir), 'r') as f: data = f.read() @@ -40,14 +38,7 @@ def get_xdr_version(dir): if not m: error('XDR_BYTECODE_VERSION is not recognized.') - version_expr = m.group(1) - - bug1066322 = False - m = bug1066322_pat.search(version_expr) - if m: - bug1066322 = True - - return (subtrahend, bug1066322) + return subtrahend quoted_pat = re.compile(r"([^A-Za-z0-9]|^)'([^']+)'") js_pat = re.compile(r"([^A-Za-z0-9]|^)(JS[A-Z0-9_\*]+)") @@ -342,7 +333,7 @@ def print_opcode(opcode): def make_element_id(name): return name.replace(' ', '-') -def print_doc(version, bug1066322, index): +def print_doc(version, index): print("""

Bytecode Listing

This document is automatically generated from @@ -356,15 +347,6 @@ def print_doc(version, bug1066322, index): version=version, actual_version=0xb973c0de - version)) - if bug1066322: - symbol_version = version + 1 - print(""" -

Until {{{{bug(1066322)}}}} is fixed, JSOP_SYMBOL exists only in Nightly, and it uses different version.

-

Bytecode version with JSOP_SYMBOL: {version} -(0x{actual_version:08x}).

-""".format(version=symbol_version, - actual_version=0xb973c0de - symbol_version)) - for (category_name, types) in index: print('

{name}

'.format(name=category_name, id=make_element_id(category_name))) @@ -384,6 +366,6 @@ if __name__ == '__main__': file=sys.stderr) sys.exit(1) dir = sys.argv[1] - (version, bug1066322) = get_xdr_version(dir) + version = get_xdr_version(dir) index = get_opcodes(dir) - print_doc(version, bug1066322, index) + print_doc(version, index)