So, that also gives me a type error:

 Type Checker: Polymorphic function `andmap' could not be applied to 
arguments:
Domains: (-> a b ... b c) (Listof a) (Listof b) ... b
         (-> a c : d) (Listof a)
Arguments: (-> Any Boolean : String) (U EOF JSExpr)

  in: (andmap string? s)


On Monday, February 25, 2019 at 3:22:12 PM UTC-8, Sam Tobin-Hochstadt wrote:
>
> I think (andmap string? ...) is probably the easiest way to check that. 
>
> Sam
>
> On Mon, Feb 25, 2019, 6:20 PM Brian Craft <[email protected] 
> <javascript:>> wrote:
>
>> In typed racket, parsing a string list gives me a JSExpr, which is a 
>> union. I need to pass it to functions that operate on string lists, but 
>> can't figure out how to please the type checker. Maybe with occurrence 
>> typing? But I don't know how to assert "this is a list of strings".
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Racket Users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to [email protected] <javascript:>.
>> For more options, visit https://groups.google.com/d/optout.
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to