rupenp / grammatical-framework

Automatically exported from code.google.com/p/grammatical-framework
0 stars 0 forks source link

Cannot overwrite oper in instances #70

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Create the following files
interface Interface = {
  oper a : Str ;
  oper b : Str ;
  oper c : Str = a ++ b ;
}
instance instance1 of Interface = { oper a = "a" ; oper b = "b" ; }
instance instance2 of Interface = instance1 - [b,c] ** { oper b = "B" ; }

2. load instance2 in the gf shell
3. call cc <a,b,c>

What is the expected output? What do you see instead?
Expected:
    {p1 = "a"; p2 = "B"; p3 = "a" ++ "B"}
Actual:
    {p1 = "a"; p2 = "b"; p3 = "a" ++ "b"}

More precisely:

> cc instance1.a
"a" -- OK

> cc instance1.b
"b" -- OK

> cc instance1.c
"a" ++ "b" -- OK

> cc instance2.a
"a" -- OK

> cc instance2.b
no occurrence of element b -- should be "B"

> cc instance2.c
no occurrence of element c -- should be "a" ++ "B"

Original issue reported on code.google.com by gregoire...@gmail.com on 21 May 2013 at 1:26

Attachments: