List Info

Thread: "ocaml_beginners"::[] to include files in the main




"ocaml_beginners"::[] to include files in the main
user name
2006-07-31 15:01:57
2006/7/31, palgirl23281 <palgirl23281yahoo.co.in>:
>
[..]
> now suppose, if I have a file named print.ml for pretty
printing and
> another evaluation.ml (for evaluation of commands like
assignmnt,
> sequence, if statement etc.), then how do I include
them in the mian
> file so as to use them..?

Some thing like that :


 let main ()=
      let lexbuf = Lexing.from_channel stdin in
      Print.printer (Evaluation.eval (P_parser.stmt
P_lexer.token lexbuf))
let _ = Printexc.print main();;

Or like that:

open Print
open Evaluation

 let main ()=
      let lexbuf = Lexing.from_channel stdin in
      printer (eval (P_parser.stmt P_lexer.token lexbuf))
let _ = Printexc.print main();;


Archives up to August 22, 2005 are also downloadable at http://www.connettivo.net/cntprojects/ocaml_beginners/
The archives of the very official ocaml list (the seniors'
one) can be found at http://caml.inria.fr
Attachments are banned and you're asked to be polite, avoid
flames etc. 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http:/
/groups.yahoo.com/group/ocaml_beginners/

<*> To unsubscribe from this group, send an email to:
    ocaml_beginners-unsubscribe@yahoogroups.com

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.c
om/info/terms/
 


[1]

about | contact  Other archives ( Real Estate discussion Medical topics )