This is certainly a case where the message could be better, perhaps we
should log it at https://github.com/elm-lang/error-message-catalog if
something similar is not already there.
Types and expressions (including Constructors) are in different namespaces.
So while there is a Type named Response, there's no Constructor named
Response, which is what the compiler is looking for in the pattern match.
What's confusing (to me) is that, when you do "type alias Foo = {field1,
field2...}", usually it generates a fake pseudo-constructor that lets you
make a record without naming fields, i.e. as "Foo x y...". But I guess
you're not allowed to pattern match with it?
On Sun, Jan 29, 2017 at 3:08 PM, jadski <[email protected]> wrote:
> Though I still don't understand why the compiler says Http does not expose
> Response - that contradicts the code?
>
> --
> You received this message because you are subscribed to the Google Groups
> "Elm Discuss" 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.
>
--
You received this message because you are subscribed to the Google Groups "Elm
Discuss" 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.