[Ur] typechecker rejects form handler

Sergey Mironov grrwlf at gmail.com
Sat Jan 4 13:57:35 EST 2014


Wow, sorry for that. Unfortunately, it is not my only trouble with
this sample. Please, see FormBug2.ur (in attach). I've replaced !=
with `eq' call.
The new errors are

 $ urweb -dbms sqlite FormBug2
 :0:0: (to 0:0) Duplicate HTTP tag validator
 :0:0: (to 0:0) Function pnew needed for both a link and a form
 Make sure that the signature of the containing module hides any form handlers.
 :0:0: (to 0:0) Function pview needed for both a link and a form
 Make sure that the signature of the containing module hides any form handlers.

Second and third errors are known (I'll check newest urweb against
them) but the first one is a mist. Could you please investigate?

Regards,
Sergey

2014/1/4 Adam Chlipala <adamc at csail.mit.edu>:
> On 01/04/2014 01:02 PM, Sergey Mironov wrote:
>>
>> Hi. Could you please take a look at the program. Looks like
>> typechecker is wrong here.
>>
>> [...]
>>        case s.Text != "" of
>>
>
>
> The issue here is just that [<>] is the not-equal operator in Ur, not [!=].
> The line above is being parsed like
>     case (s.Text !) = "" of
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: FormBug2.ur
Type: application/octet-stream
Size: 2087 bytes
Desc: not available
URL: <http://www.impredicative.com/pipermail/ur/attachments/20140104/15f30249/attachment.obj>


More information about the Ur mailing list