Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

XQuery: Updating expressions, type checks, inspect:functions #2221

Open
ChristianGruen opened this issue Jun 26, 2023 · 1 comment
Open

XQuery: Updating expressions, type checks, inspect:functions #2221

ChristianGruen opened this issue Jun 26, 2023 · 1 comment
Labels

Comments

@ChristianGruen
Copy link
Member

ChristianGruen commented Jun 26, 2023

(: a.xqm :)
module namespace a = 'a';
(: b.xqm :)
module namespace b = 'b';
(: c.xqm :)
module namespace c = 'c';
declare %updating function c:a() as empty-sequence() { error(), c:a() };

The following query…

(: main.xq :)
import module namespace c = 'c' at 'c.xqm';
('a.xqm', 'b.xqm') ! inspect:functions(.)

…returns:

[inspect:parse] Stopped at c.xqm, 3/28:
[XUST0001] type check: no updating expression allowed.
@ChristianGruen ChristianGruen changed the title inspect:functions(): Multiple invocations XQuery: Updating expressions, type checks, inspect:functions Jul 5, 2023
@ChristianGruen
Copy link
Member Author

Related (with INLINELIMIT = 0):

(: x.xqm :)
module namespace f = 'f';
declare function f:f() { };
(: x.xq :)
declare function local:a() { current-date()[not(string(.))] };
declare %updating function local:b() { void(local:a()) ,() };
void(inspect:functions('x.xqm')),
local:b()

Unexpected result: Function body must be updating.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant