From: Chris King <colanderman@gmail.com>
To: "O'Caml Mailing List" <caml-list@inria.fr>
Subject: yacc style
Date: Thu, 27 Jan 2005 15:17:13 -0500 [thread overview]
Message-ID: <875c7e0705012712177a9e852@mail.gmail.com> (raw)
I'm defining a grammar which, when parsed, returns an imperative
structure (i.e. one which can't easily be created in a functional
style). ocamlyacc is making this difficult for me, since there's no
clean way to pass to the main parser function a structure on which to
operate. Right now I'm getting around this by defining global
references in the header of the parser and setting them before each
call to the parser main function. Is it considered better style to
instead have the parser return a parse tree, and then use that to
generate the imperative structure, or is there a more direct way to do
what I want to do?
Thanks!
next reply other threads:[~2005-01-27 20:17 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-01-27 20:17 Chris King [this message]
2005-01-27 21:39 ` [Caml-list] " Erik de Castro Lopo
2005-01-28 1:14 ` skaller
2005-01-28 2:28 ` Erik de Castro Lopo
2005-01-28 4:30 ` skaller
2005-01-28 9:04 ` Jean-Christophe Filliatre
[not found] ` <200501272252.43720.jon@jdh30.plus.com>
2005-01-28 0:41 ` Chris King
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=875c7e0705012712177a9e852@mail.gmail.com \
--to=colanderman@gmail.com \
--cc=caml-list@inria.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox