Mizero / grammatical-framework

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

Function not properly hidden #63

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
Here is a simplified test case consisting of three files:
Test.gf
    abstract Test = {
      cat S ;
      fun a,b,c : S ;
    }

TestA.gf
    concrete TestA of Test = {
      lincat S = Str ;
      lin a = "a";
          b = "b";
          c = "c";
    }

TestB.gf
    concrete TestB of Test = TestA - [b,c] ** {
      lin b = "B" ;
          c = b ;
    }

What is the expected output? What do you see instead?

I expect TestB.c to be "B", instead I get the following error that seems to 
indicate that the compiler looks at both TestA.b and TestB.b when compiling 
TestB.c although TestA.b is supposed to be hidden

Error message:
/home/gregoire/TestB.gf:3:
Happened in the renaming of c
   Warning: atomic term b
            conflict TestA.b, TestB.b
            given TestA, TestB

/home/gregoire/TestB.gf:3:
  Happened in linearization of c
   cannot infer type of constant b

Original issue reported on code.google.com by gregoire...@gmail.com on 11 Apr 2013 at 9:50

GoogleCodeExporter commented 8 years ago
Note that there is a workarround: write TestB.b. But I still think this is a 
bug.

Original comment by gregoire...@gmail.com on 11 Apr 2013 at 9:55