Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
[Caml-list] stream parser problem/question
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2004-08-10 (09:52)
From: Michael <micha-1@f...>
Subject: [Caml-list] stream parser problem/question

I'm using ocamllex/yacc to translate a little language into a parse-tree, then 
processing the tree and putting the output into a queue. Then I iterate over 
the queue, generating a new one and so on until finished.
My question is, instead of outputing the processed parse-tree into a queue, is 
ist better/more elegant to generate a stream and then using a stream parser 
to process that stream and eventual generating a new stream,... until 
Are stream parsers useful for my purpose? Are there penalties using them?

Another slight issue is, that I don't see how to generate a token stream (with 
Stream.from) of my parse tree (because of the tree-stucture, I get confused 
how to get the right next token); maybe someone can give me a hint?


To unsubscribe, mail Archives:
Bug reports: FAQ:
Beginner's list: