Changeset 422 for proto


Ignore:
Timestamp:
Jul 2, 2010, 12:44:57 PM (9 years ago)
Author:
eamiri
Message:

reading template from the input file directory

File:
1 edited

Legend:

Unmodified
Added
Removed
  • proto/Compiler/bitstream_compiler.py

    r421 r422  
    2020        return templ
    2121
    22     def read_template(self):
    23         f=open(sys.path[0] + "/" + self.templ_name)
     22    def read_template(self, file_path):
     23        f=open(file_path + self.templ_name)
    2424        inp = ""
    2525        for line in f:
     
    5454        # BACK END
    5555        declarations = py2bitexpr.gen_declarations(s)
    56         templ = self.read_template()
     56        templ = self.read_template(file_path)
    5757
    5858        templ = self.output(declarations, py2bitexpr.print_prog(s), templ)
Note: See TracChangeset for help on using the changeset viewer.