Merge lp:~zorba-coders/zorba/xquery_visitor into lp:zorba

Proposed by William Candillon
Status: Merged
Approved by: Matthias Brantner
Approved revision: 10859
Merged at revision: 10859
Proposed branch: lp:~zorba-coders/zorba/xquery_visitor
Merge into: lp:zorba
Diff against target: 57 lines (+32/-4)
1 file modified
src/compiler/parsetree/parsenode_print_xquery_visitor.cpp (+32/-4)
To merge this branch: bzr merge lp:~zorba-coders/zorba/xquery_visitor
Reviewer Review Type Date Requested Status
Matthias Brantner Approve
William Candillon Approve
Review via email: mp+106490@code.launchpad.net

Commit message

Add support for function items test in the print xquery visitor.

Description of the change

Add support for function items test in the print xquery visitor.

To post a comment you must log in.
Revision history for this message
William Candillon (wcandillon) :
review: Approve
Revision history for this message
Matthias Brantner (matthias-brantner) :
review: Approve
Revision history for this message
Zorba Build Bot (zorba-buildbot) wrote :
Revision history for this message
Zorba Build Bot (zorba-buildbot) wrote :

The attempt to merge lp:~zorba-coders/zorba/xquery_visitor into lp:zorba failed. Below is the output from the failed tests.

CMake Error at /home/ceej/zo/testing/zorbatest/tester/TarmacLander.cmake:274 (message):
  Validation queue job xquery_visitor-2012-05-21T19-09-00.923Z is finished.
  The final status was:

  No tests were run - build or configure step must have failed.

  Not commiting changes.

Error in read script: /home/ceej/zo/testing/zorbatest/tester/TarmacLander.cmake

Revision history for this message
Zorba Build Bot (zorba-buildbot) wrote :
Revision history for this message
Zorba Build Bot (zorba-buildbot) wrote :

Validation queue job xquery_visitor-2012-05-21T19-53-16.437Z is finished. The final status was:

All tests succeeded!

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/compiler/parsetree/parsenode_print_xquery_visitor.cpp'
2--- src/compiler/parsetree/parsenode_print_xquery_visitor.cpp 2012-05-03 12:31:51 +0000
3+++ src/compiler/parsetree/parsenode_print_xquery_visitor.cpp 2012-05-21 19:07:37 +0000
4@@ -1869,11 +1869,42 @@
5
6 os << "{";
7 n.getExprSingle()->accept(*this);
8- os << '}';
9+ os << "}";
10 return 0;
11 }
12 DEFAULT_END_VISIT (CatchExpr);
13
14+ void* begin_visit(const AnyFunctionTest& n)
15+ {
16+ os << "function (*)";
17+ return 0;
18+ }
19+ DEFAULT_END_VISIT (AnyFunctionTest);
20+
21+ void* begin_visit(const TypedFunctionTest& n)
22+ {
23+ os << "function (";
24+ n.getArgumentTypes()->accept(*this);
25+ os << ") as ";
26+ n.getReturnType()->accept(*this);
27+ return 0;
28+ }
29+ DEFAULT_END_VISIT (TypedFunctionTest);
30+
31+ void* begin_visit(const TypeList& n)
32+ {
33+ for (size_t i = 0; i < n.size(); ++i)
34+ {
35+ if (i > 0)
36+ {
37+ os << ", ";
38+ }
39+ const SequenceType* e_p = n[i];
40+ e_p->accept(*this);
41+ }
42+ return 0;
43+ }
44+ DEFAULT_END_VISIT (TypeList);
45
46 /* full-text-related */
47 DEFAULT_VISIT (FTAnd);
48@@ -1921,9 +1952,6 @@
49
50 DEFAULT_VISIT (LiteralFunctionItem);
51 DEFAULT_VISIT (InlineFunction);
52- DEFAULT_VISIT (AnyFunctionTest);
53- DEFAULT_VISIT (TypeList);
54- DEFAULT_VISIT (TypedFunctionTest);
55 DEFAULT_VISIT (DynamicFunctionInvocation);
56
57 DEFAULT_VISIT (ParseErrorNode);

Subscribers

People subscribed via source and target branches