Skip to content

Commit

Permalink
Bug 1506380 - Rename opcode.py to avoid conflict with builtin Python …
Browse files Browse the repository at this point in the history
…module. r=arai

Differential Revision: https://phabricator.services.mozilla.com/D11568

--HG--
rename : js/src/vm/opcode.py => js/src/vm/jsopcode.py
extra : moz-landing-system : lando
  • Loading branch information
ptomato committed Nov 12, 2018
1 parent 69825a3 commit 97ccc8c
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions config/check_js_opcode.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@ def log_fail(text):

def check_opcode():
sys.path.insert(0, os.path.join(topsrcdir, 'js', 'src', 'vm'))
import opcode
import jsopcode

try:
opcode.get_opcodes(topsrcdir)
jsopcode.get_opcodes(topsrcdir)
except Exception as e:
log_fail(e.args[0])
return False
Expand Down
File renamed without changes.
4 changes: 2 additions & 2 deletions js/src/vm/make_opcode_doc.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

import os
sys.path.insert(0, os.path.dirname(os.path.realpath(__file__)))
import opcode
import jsopcode

from xml.sax.saxutils import escape

Expand Down Expand Up @@ -139,7 +139,7 @@ def print_doc(index):
dir = sys.argv[1]

try:
index, _ = opcode.get_opcodes(dir)
index, _ = jsopcode.get_opcodes(dir)
except Exception as e:
print("Error: {}".format(e.args[0]), file=sys.stderr)
sys.exit(1)
Expand Down

0 comments on commit 97ccc8c

Please sign in to comment.