Skip to Content.
Sympa Menu

k-user - Re: [K-user] Using an external parser

k-user AT lists.cs.illinois.edu

Subject: K-user mailing list

List archive

Re: [K-user] Using an external parser


Chronological Thread 
  • From: Joshua Cranmer <cranmer2 AT illinois.edu>
  • To: Radu Mereuta <headness13 AT gmail.com>
  • Cc: k-user AT cs.uiuc.edu
  • Subject: Re: [K-user] Using an external parser
  • Date: Mon, 10 Dec 2012 16:01:38 -0600
  • List-archive: <http://lists.cs.uiuc.edu/pipermail/k-user/>
  • List-id: <k-user.cs.uiuc.edu>

On 12/10/2012 3:40 PM, Radu Mereuta wrote:
I hope this helps.
You need to modify your parser to create a K like AST. You can look at some examples in the K distribution and use the `kast` tool on some small programs to see how it looks like. To integrate your external parser, you need to call krun with the option -parser.
Type `krun --help` to get more information (like below).
--parser <STRING> Command used to parse programs (default: kast).
You need to specify the path where you parser
is located on the disk

If you still have problems, then I think Dwight can give you more details.
So, Dwight, any thoughts?

The main issue is that the string passed into the constructor isn't statically known (think var a = "a*b"; new RegExp(a))...
-- 
Joshua Cranmer
Source code archæologist



Archive powered by MHonArc 2.6.16.

Top of Page