some fixes in terms of map

Mainly, make a intermediate function to get the keys we want. 
Guys, we do not want to switch to the new version of K which is now being baked in the unified-builtins2 branch until we are sure that the new version has error messages as good as the current version.  We want to never look back once we do the merge/switch!  Therefore, I urge you as strongly as one can do it, to report all problems like this as issues in the K repository!  Liyi, PLEASE do it!!!  I know it takes time to do it, but it really helps us, because we are not going to do the migration until we fix all the issues.

Thank you,
Grigore


________________________________
From: Chris Hathhorn [notifications@github.com]
Sent: Friday, June 06, 2014 1:41 PM
To: kframework/c-semantics
Subject: Re: [c-semantics] some fixes in terms of map (#10)


In semantics/language/common/memory/writing.k:

>            [structural]
>
>       syntax KItem ::= makeUnknown(SymLoc, CId, FieldInfo)
> +             | makeUnionUnKnown(K,Set)
> +
> +     rule makeUnionUnKnown(.K,.Set) => . [structural]
> +     rule makeUnionUnKnown(.K,SetItem(K) S:Set)
> +       => makeUnionUnKnown(K,S)
> +       [structural]
> +     rule makeUnionUnKnown(fromUnion(UnionLoc:SymLoc, F:CId,
> +              Fields:FieldInfo),S:Set)
> +       => allowInit(makeUnknown(UnionLoc, F, Fields)) ~> makeUnionUnKnown(K,S)


I guess that should be ".K" instead of "K"-- it might be good to run this through the maude backend occasionally to pick up these issues, but I suppose they'll be caught eventually regardless.

—
Reply to this email directly or view it on GitHub<https://github.com/kframework/c-semantics/pull/10/files#r13504393>.