k-user AT lists.cs.illinois.edu
Subject: K-user mailing list
List archive
- From: Derek Sorensen <derek AT pyrofex.net>
- To: k-user AT lists.cs.illinois.edu
- Subject: [[K-user] ] Strange syntax
- Date: Mon, 4 Jun 2018 12:54:03 -0600
- Authentication-results: illinois.edu; spf=pass smtp.mailfrom=derek AT pyrofex.net; dkim=pass header.d=pyrofex-net.20150623.gappssmtp.com header.s=20150623; dmarc=none
Hi all,
I’m experiencing a bit of an odd phenomenon. I’m taking something in a k-cell and putting it in a cell of the form <out> … </out>. The rewrite rule is as follows:
rule (<k> C:Chan!(P:HigherProcs) </k> => <out> C!(P) </out>)
When this rewrite occurs, K introduces underscores, back ticks, commas and single quotes intermittently that makes it difficult to read. For example,
@“chan”!(20)
will rewrite as
‘@_(“chan”)!`(20`).
K will even sometimes get so weird as to rewrite
for(@ @10!(x) <- chan){ Nil }
as
{for( '@_( '@_(10)!`( #symId("local",, 1)`) ) <- @ {chan} ){
Nil }}
I’m trying to get an idea with what’s going on so I can keep the syntax clean and nice when it outputs. Any suggestions?
Best,
Derek Sorensen
- [[K-user] ] Strange syntax, Derek Sorensen, 06/04/2018
- Re: [[K-user] ] Strange syntax, Mike Stay, 06/07/2018
Archive powered by MHonArc 2.6.19.