Skip to Content.
Sympa Menu

maude-help - [Maude-help] Re: another minor probem with parameterized modules

maude-help AT lists.cs.illinois.edu

Subject: Maude-help mailing list

List archive

[Maude-help] Re: another minor probem with parameterized modules


Chronological Thread 
  • From: Martin <br_marty AT yahoo.com>
  • To: maude-help AT banyan.cs.uiuc.edu
  • Subject: [Maude-help] Re: another minor probem with parameterized modules
  • Date: Mon, 8 Dec 2003 19:39:26 +0000 (GMT)
  • List-archive: <http://maude.cs.uiuc.edu/pipermail/maude-help/>
  • List-id: Maude help list <maude-help.maude.cs.uiuc.edu>

this is a slightly modified version (this time clearly
with subsort overloading on ops defined in a paramter,
which should not work, but making the subsort
overloading explicit does nothing to change the
situation; apart from that) one that should be working
as well, however the error remains

it appears that the concatenation operator introduces
some kind of error, im profoundly unable to determine
exactly what is happening

i can only plea for help, as this must be a majorly
trivial problem,

sincerely, martin

-------------------

(fmod PATH(G :: GRAPH) is
sort Path .
subsort
G@Edge
< Path .

ops s t : Path ->
G@Node
.

var E :
G@Edge
.
var P : Path .

op _;_ : [Path] [Path] -> [Path] [assoc] .
cmb E ; P : Path if t(E) = s(P) .
eq s(E ; P) = s(E) .
eq t(E ; P) = t(P) .

endfm)

------------------------

where "Pmod" is the trivial "protecting PATH(Graph)"
module and "Graph" the appropriate View:

Maude> (red in Pmod : ab .)

will not work, nor does (error messages are pretty
similar):

Maude> (red in Pmod : s(ab ; bc) .)

Advisory: bad operator declaration
eSortToSort(applyMapSetToOpDeclSet((sort

'G@Edge
to 'Edge),sort
'G@Node
to 'Node, op 's :
'G@Edge
->
'G@Node
to 's[
none],op 't :
'G@Edge
->
'G@Node
to 't[none], op
'_;_ : kind('Path) kind(
'Path) -> kind('Path) [assoc] ., fmod 'PATH is
protecting 'BOOL .
sorts
'G@Edge
;
'G@Node
; 'Path .
subsort
'G@Edge
< 'Path .
op '_;_ : '`[Path`] '`[Path`] -> '`[Path`] [assoc] .
op 's :
'G@Edge
->
'G@Node
[none] .
op 'src : 'Path ->
'G@Node
[none] .
op 't :
'G@Edge
->
'G@Node
[none] .
op 'tar : 'Path ->
'G@Node
[none] .
cmb
'_;_['E:G@Edge,'P:Path]
: 'Path if
'tar['E:G@Edge]
= 'src['P:Path] [none]
.
eq
'src['E:G@Edge]
=
's['E:G@Edge]
[none] .
eq
'src['_;_['E:G@Edge,'P:Path]]
=
'src['E:G@Edge]
[none] .
eq
'tar['E:G@Edge]
=
't['E:G@Edge]
[none] .
eq
'tar['_;_['E:G@Edge,'P:Path]]
= 'tar['P:Path]
[none] .
endfm)) in meta-module Pmod.
Advisory: bad operator declaration
eSortToSort(applyMapSetToOpDeclSet((sort

'G@Edge
to 'Edge),sort
'G@Node
to 'Node, op 's :
'G@Edge
->
'G@Node
to 's[
none],op 't :
'G@Edge
->
'G@Node
to 't[none], op
'_;_ : kind('Path) kind(
'Path) -> kind('Path) [assoc] ., fmod 'PATH is
protecting 'BOOL .
sorts
'G@Edge
;
'G@Node
; 'Path .
subsort
'G@Edge
< 'Path .
op '_;_ : '`[Path`] '`[Path`] -> '`[Path`] [assoc] .
op 's :
'G@Edge
->
'G@Node
[none] .
op 'src : 'Path ->
'G@Node
[none] .
op 't :
'G@Edge
->
'G@Node
[none] .
op 'tar : 'Path ->
'G@Node
[none] .
cmb
'_;_['E:G@Edge,'P:Path]
: 'Path if
'tar['E:G@Edge]
= 'src['P:Path] [none]
.
eq
'src['E:G@Edge]
=
's['E:G@Edge]
[none] .
eq
'src['_;_['E:G@Edge,'P:Path]]
=
'src['E:G@Edge]
[none] .
eq
'tar['E:G@Edge]
=
't['E:G@Edge]
[none] .
eq
'tar['_;_['E:G@Edge,'P:Path]]
= 'tar['P:Path]
[none] .
endfm)) in meta-module Pmod.
rewrites: 499 in 110ms cpu (281ms real) (4536
rewrites/second)
Error: Incorrect command.

________________________________________________________________________
BT Yahoo! Broadband - Save £80 when you order online today. Hurry! Offer ends
21st December 2003. The way the internet was meant to be.
http://uk.rd.yahoo.com/evt=21064/*http://btyahoo.yahoo.co.uk




Archive powered by MHonArc 2.6.16.

Top of Page