<html>
<head>
<meta content="text/html; charset=windows-1252"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">On 07/28/2015 02:50 AM, Stefan Scott
Alexander wrote:<br>
</div>
<blockquote
cite="mid:CAFwK6atGSptf=OAYdGcJrbtxtGkvMBgSOrjYNS+UW_vUeXFBJA@mail.gmail.com"
type="cite">
<div dir="ltr"><font face="monospace, monospace">But wait! Let's
do one more test:</font>
<div><font face="monospace, monospace"><br>
</font></div>
<div><font face="monospace, monospace">(2) If we *replace* the
2nd statement with a copy of the 1st statement (and in the
2nd copy we change 'thingRows' to 'thingRows2' - and we also
again remove references to 'colorOptions' elsewhere in my
code), then the code looks like this:</font></div>
<div><font face="monospace, monospace"><br>
</font></div>
<div><font face="monospace, monospace"> thingRows <- </font></div>
<div><font face="monospace, monospace"> queryX1 (SELECT *
FROM thing)</font></div>
<div><font face="monospace, monospace"> (fn r =>
<xml> <tr> </font></div>
<div><font face="monospace, monospace"> <td>
{[r.TId]} </td> </font></div>
<div><font face="monospace, monospace"> <td>
{[r.TNam]} </td> </font></div>
<div><font face="monospace, monospace"> <td>
{[r.Color]} </td> </font></div>
<div><font face="monospace, monospace"> </tr>
</xml>);</font></div>
<div><font face="monospace, monospace"><br>
</font></div>
<div><font face="monospace, monospace"> thingRows2 <- </font></div>
<div><font face="monospace, monospace"> queryX1 (SELECT *
FROM thing)</font></div>
<div><font face="monospace, monospace"> (fn r =>
<xml> <tr> </font></div>
<div><font face="monospace, monospace"> <td>
{[r.TId]} </td> </font></div>
<div><font face="monospace, monospace"> <td>
{[r.TNam]} </td> </font></div>
<div><font face="monospace, monospace"> <td>
{[r.Color]} </td> </font></div>
<div><font face="monospace, monospace"> </tr>
</xml>);</font></div>
<div><font face="monospace, monospace"><br>
</font></div>
<div><font face="monospace, monospace">AND NOW WE GET THE SAME
COMPILE ERROR AS PREVIOUSLY (before we did any
modifications):</font></div>
<div><font face="monospace, monospace"><br>
</font></div>
<div><font face="monospace, monospace"> "Some constructor
unification variables are undetermined in declaration".</font></div>
</div>
</blockquote>
<br>
I recommend thinking more about the meanings of the error messages,
instead of thinking of them as magic incantations. ;)<br>
<br>
As I wrote in my previous message, the other code that you removed
really was the problem, and it makes sense why it would be.<br>
<br>
Your modification (2) introduces a new problem: variable
[thingRows2] is defined but never used, and the usage context gave
crucial information to determine its precise type. Without that
information, its type contains at least one undetermined unification
variable.<br>
<br>
Why would the type be unclear from context above? Ur/Web XML types
include information on which form variables are bound and used. The
code above is not sufficient to tell which form variables may be in
scope for the generated XHTML.<br>
</body>
</html>