type errors cause ugly error msgs
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Zorba |
Fix Released
|
Medium
|
Markos Zaharioudakis |
Bug Description
A query like this
declare function local:foo() as empty-sequence()
{
<foo />
};
local:foo();
causes the following error msg because of a type error:
<?xml version="1.0" encoding="UTF-8"?>
</Users/
treat [NodeXQType elementNode nametest=[uri: , local: foo]
content=[XQType ANY_TYPE_KIND*]] as [XQType NONE_KIND] when returning
the result of the function local:foo().; raised at
/Users/
=======
local:foo#0 <http://
/Users/
This is very ugly und not understandable for someone who is not involved in the zorba internals. We need an error msg like this:
Stopped at line 1, column 17: [XPTY0004] Can't promote type xs:string to empty-sequence(): "abc".
Changed in zorba: | |
assignee: | nobody → Markos Zaharioudakis (markos-za) |
Changed in zorba: | |
status: | New → In Progress |
Changed in zorba: | |
importance: | Undecided → Medium |
Changed in zorba: | |
milestone: | none → 2.7 |
status: | In Progress → Fix Committed |
Changed in zorba: | |
milestone: | 2.7 → 2.6 |
status: | Fix Committed → Fix Released |