cmpl.go 312 B

123456789101112131415161718
  1. package otto
  2. import (
  3. "github.com/robertkrimen/otto/ast"
  4. "github.com/robertkrimen/otto/file"
  5. )
  6. type _compiler struct {
  7. file *file.File
  8. program *ast.Program
  9. }
  10. func (cmpl *_compiler) parse() *_nodeProgram {
  11. if cmpl.program != nil {
  12. cmpl.file = cmpl.program.File
  13. }
  14. return cmpl._parse(cmpl.program)
  15. }