Hi Doug: >From dougo@ccs.neu.edu Fri Aug 1 16:43:29 1997 >From: Doug Orleans >To: Karl Lieberherr >Cc: boaz@ccs.neu.edu >Subject: Re: special cases > >Karl Lieberherr writes: > > Hi Boaz: > > > > do you agree with the following two special cases? > > I think that the first is not handled by our paper. We should add it. > > > > Doug, how does your implementation handle those two special cases? > > > > -- Karl > > > > > > Special case 1: > > ============================= > > > > Strategy graph S: > > > > A (no edges, only one node) > > ---------------- > > Class graph C: > > > > A = B. > > B = . > > > > PathSet_S(C) = the single node path consisting of A. > > > > This property is important so that we can say that a method > > is a degenerate traversal: we visit only one object. > >This isn't currently expressible in Demeter/Java. A strategy graph is >defined as a nonempty list of edges. I suppose I could modify it to >allow an empty list. Let's keep it the way it currently is since you have the other way of distributing code. > > > =================== > > Special case 2: > > ============================= > > > > > > Strategy graph S: > > > > from A to A (two different strategy graph nodes) > > ---------------- > > Class graph C: > > > > A = . > > > > PathSet_S(C) = the single node path consisting of A. > >Actually, the strategy graph "{ A -> A }" is represented as a single node >with an edge to itself, rather than two separate nodes. This probably >needs to be changed, but for this case in particular I guess it >doesn't make a difference. > >--Doug > I see: for strategy graphs same label means same node in the current Demeter/Java. Consider: One_A: (Demeter/Java syntax and meaning) { A -> B bypassing {A,B} B -> A bypassing {A,B} } Two_A: { x1:A -> B bypassing {A,B} B -> x3:A bypassing {A,B} } Here, there is a difference between the two: A B A B A is accepted by One_A but not by Two_A. Since you allow several forms of expression for strategies: StrategyExpression : StrategyGraph | PathDirective | StrategyVariable | CompoundStrategy. your policy: "same label implies same node" seems to be a good one for StrategyGraph. Why don't you keep that and we will see whether we get into problems. -- Karl