List Info

Thread: "ocaml_beginners"::[] Genlex, parser, and [<




"ocaml_beginners"::[] Genlex, parser, and [<
user name
2006-08-04 19:51:05
Brian N. Makin wrote:

> Anytime I try any of the example code with deals with
streams and [<
> ... >] syntax I get a Syntax Error on '[<'
> 
> for example
> # [< '1 >] ;;
> ^^
> Syntax error
> 
> what might I be doing ?

You're just following instructions. Unfortunately, the
instructions 
aren't very clear on one essential point: you need CamlP4
to support the 
stream literal ('[< ... >]') syntax. So, in the
toplevel:

   # #load "camlp4o.cmo";;

Or when compiling:

   ocamlc camlp4o.cmo mycode.ml

-- 
Matt Gushee
: Bantam - lightweight file manager :
matt.gushee.net/software/bantam/ :
: RASCL's A Simple Configuration Language :    
matt.gushee.net/rascl/ :


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/
 


"ocaml_beginners"::[] Genlex, parser, and [<
user name
2006-08-04 20:16:08
dangit, I thought I had tried that.

thank you very much.

--- In ocaml_beginners@yahoogroups.com, Matt Gushee
<matt...> 
wrote:
>
> Brian N. Makin wrote:
> 
> > Anytime I try any of the example code with deals
with streams 
and [<
> > ... >] syntax I get a Syntax Error on '[<'
> > 
> > for example
> > # [< '1 >] ;;
> > ^^
> > Syntax error
> > 
> > what might I be doing ?
> 
> You're just following instructions. Unfortunately, the

instructions 
> aren't very clear on one essential point: you need
CamlP4 to 
support the 
> stream literal ('[< ... >]') syntax. So, in the
toplevel:
> 
>    # #load "camlp4o.cmo";;
> 
> Or when compiling:
> 
>    ocamlc camlp4o.cmo mycode.ml
> 
> -- 
> Matt Gushee
> : Bantam - lightweight file manager : 
matt.gushee.net/software/bantam/ :
> : RASCL's A Simple Configuration Language :     
matt.gushee.net/rascl/ :
>






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/
 



"ocaml_beginners"::[] Genlex, parser, and [<
user name
2006-08-04 20:22:15
I'd rather to that:
(toplevel)
#load "camlp4o.cma";;

(compilation)
ocamlc -pp camlp4o toto.ml


--
Martin Jambon, PhD
http://martin.jambon.fre
e.fr


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/
 



"ocaml_beginners"::[] Genlex, parser, and [<
user name
2006-08-04 20:31:33
Martin Jambon wrote:

> I'd rather to that:
> (toplevel)
> #load "camlp4o.cma";;
> 
> (compilation)
> ocamlc -pp camlp4o toto.ml

Yes, you're right. Sorry.

-- 
Matt Gushee
: Bantam - lightweight file manager :
matt.gushee.net/software/bantam/ :
: RASCL's A Simple Configuration Language :    
matt.gushee.net/rascl/ :


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-4]

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