Enable nivision Java wrappers to be generated with Python 3.

Change-Id: I8ce57874e4730ed10dd0093c147b14c22f141201
This commit is contained in:
Peter Johnson
2015-01-15 00:04:23 -08:00
parent d0258923e8
commit 5d95bbb33f

View File

@@ -1,4 +1,5 @@
from __future__ import print_function
import codecs
import sys
import os
import re
@@ -1947,7 +1948,7 @@ def generate(srcdir, outdir, inputs):
library_funcs.add(line.strip())
# open input file
with open(fname) as inf:
with codecs.open(fname, encoding="utf-8", errors="ignore") as inf:
# prescan for undefined structures
prescan_file(inf)
inf.seek(0)