[system] / trunk / pg / lib / Value / Formula.pm Repository:
ViewVC logotype

Diff of /trunk/pg/lib/Value/Formula.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 5508 Revision 5509
73 my $formula = $self->blank($self->context); 73 my $formula = $self->blank($self->context);
74 if (ref($r) eq $class || ref($r) eq $pkg) { 74 if (ref($r) eq $class || ref($r) eq $pkg) {
75 $formula->{context} = $r->{context}; 75 $formula->{context} = $r->{context};
76 $r = $r->{tree}->copy($formula); 76 $r = $r->{tree}->copy($formula);
77 } else { 77 } else {
78 $r = $self->new($r)->{tree}; 78 $r = $self->new($r)->{tree}->copy($formula);
79 } 79 }
80 if (ref($l) eq $class || ref($l) eq $pkg) { 80 if (ref($l) eq $class || ref($l) eq $pkg) {
81 $formula->{context} = $l->{context}; 81 $formula->{context} = $l->{context};
82 $l = $l->{tree}->copy($formula); 82 $l = $l->{tree}->copy($formula);
83 } else { 83 } else {
84 $l = $self->new($l)->{tree}; 84 $l = $self->new($l)->{tree}->copy($formula);
85 } 85 }
86 $bop = 'U' if $bop eq '+' && 86 $bop = 'U' if $bop eq '+' &&
87 ($l->type =~ m/Interval|Set|Union/ || $r->type =~ m/Interval|Set|Union/); 87 ($l->type =~ m/Interval|Set|Union/ || $r->type =~ m/Interval|Set|Union/);
88 $formula->{tree} = $formula->Item("BOP")->new($formula,$bop,$l,$r); 88 $formula->{tree} = $formula->Item("BOP")->new($formula,$bop,$l,$r);
89 $formula->{variables} = $formula->{tree}->getVariables; 89 $formula->{variables} = $formula->{tree}->getVariables;

Legend:
Removed from v.5508  
changed lines
  Added in v.5509

aubreyja at gmail dot com
ViewVC Help
Powered by ViewVC 1.0.9