Dear Torsten,
thanks for the bug report, always welcome. The issue is related to the "Info View" in the GUI or, more exactly, the generation of the query plan, which was triggering a recursive loop. It was running fine when the Info View was deactivated (which was the reason why I first couldn't reproduce the issue locally).
We haven't implemented yet a general solution to the core issue (which is discussed in [1] in more detail). Instead, I have just uploaded a latest stable snapshot, which will simply skip some details in the serialized query plan, and won't raise any errors anymore.
Hope this helps, Christian
[1] https://github.com/BaseXdb/basex/issues/566 [2] http://files.basex.org/releases/latest/ ___________________________
On Tue, Sep 18, 2012 at 10:02 AM, Torsten Grust torsten.grust@gmail.com wrote:
Dear all,
I have been playing with the following toy implementation of a super-simple associative map (it's mainly an exercise in demonstrating the use of h-o functions in XQuery 3.0):
declare namespace map = "http://db.inf.uni-tuebingen.de/map";
declare function map:entry($map, $k, $v) { function($x) { if ($x eq $k) then $v else $map($x) } };
declare function map:empty() { function($x) { () } };
let $map := map:empty(), $map1 := map:entry($map, 1, ("one", "eins", "uno")), $map2 := map:entry($map1, 2, ("two", "zwei", "due")) return $map2(1)
The execution of this script with BaseX 7.3 unexpectedly yields
Stack Overflow: circular variable declaration?
Note that replacing $map2(1) by $map1(1) in the last line returns the expected result ("one", "eins", "uno").
I'd be grateful for any comment/insight.
Cheers and keep up the good work, --Torsten
-- | Prof. Dr. Torsten Grust | Database Systems — Universität Tübingen (Germany) | torsten.grust@uni-tuebingen.de | db.inf.uni-tuebingen.de _______________________________________________ BaseX-Talk mailing list BaseX-Talk@mailman.uni-konstanz.de https://mailman.uni-konstanz.de/mailman/listinfo/basex-talk