You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@vxquery.apache.org by ti...@apache.org on 2014/03/14 23:09:44 UTC
[23/25] git commit: Changed the function name to be more consistent
with other classes.
Changed the function name to be more consistent with other classes.
Project: http://git-wip-us.apache.org/repos/asf/incubator-vxquery/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-vxquery/commit/b594f027
Tree: http://git-wip-us.apache.org/repos/asf/incubator-vxquery/tree/b594f027
Diff: http://git-wip-us.apache.org/repos/asf/incubator-vxquery/diff/b594f027
Branch: refs/heads/westmann/prettyprint
Commit: b594f0273c55119fd15e64df8a2f15fcaaa8c44b
Parents: ef04365
Author: Preston Carman <pr...@apache.org>
Authored: Wed Feb 19 11:19:37 2014 -0800
Committer: Preston Carman <pr...@apache.org>
Committed: Wed Feb 19 11:19:37 2014 -0800
----------------------------------------------------------------------
.../rewriter/rules/RemoveRedundantTreatExpressionsRule.java | 2 +-
.../apache/vxquery/runtime/functions/type/SequenceTypeMatcher.java | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/b594f027/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/RemoveRedundantTreatExpressionsRule.java
----------------------------------------------------------------------
diff --git a/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/RemoveRedundantTreatExpressionsRule.java b/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/RemoveRedundantTreatExpressionsRule.java
index ef23f30..60058bc 100644
--- a/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/RemoveRedundantTreatExpressionsRule.java
+++ b/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/RemoveRedundantTreatExpressionsRule.java
@@ -57,7 +57,7 @@ public class RemoveRedundantTreatExpressionsRule extends AbstractRemoveRedundant
public boolean matchesAllInstancesOf(SequenceType sTypeArg, SequenceType sTypeOutput) {
if (sTypeArg != null) {
stm.setSequenceType(sTypeArg);
- if (sTypeOutput != null && stm.isSubType(sTypeOutput)) {
+ if (sTypeOutput != null && stm.matchesAllInstances(sTypeOutput)) {
return true;
}
}
http://git-wip-us.apache.org/repos/asf/incubator-vxquery/blob/b594f027/vxquery-core/src/main/java/org/apache/vxquery/runtime/functions/type/SequenceTypeMatcher.java
----------------------------------------------------------------------
diff --git a/vxquery-core/src/main/java/org/apache/vxquery/runtime/functions/type/SequenceTypeMatcher.java b/vxquery-core/src/main/java/org/apache/vxquery/runtime/functions/type/SequenceTypeMatcher.java
index 5142ac4..12d0d93 100644
--- a/vxquery-core/src/main/java/org/apache/vxquery/runtime/functions/type/SequenceTypeMatcher.java
+++ b/vxquery-core/src/main/java/org/apache/vxquery/runtime/functions/type/SequenceTypeMatcher.java
@@ -153,7 +153,7 @@ public class SequenceTypeMatcher {
return false;
}
- public boolean isSubType(SequenceType testST) {
+ public boolean matchesAllInstances(SequenceType testST) {
Quantifier stq = sequenceType.getQuantifier();
ItemType it = sequenceType.getItemType();
if (stq.isSubQuantifier(testST.getQuantifier())) {