The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

tusharsamant (4) [Avatar] Offline
The first four chapters, as of January 15, are really lucid.

One question about this on page 73: "... union type constructors like Just are functions with capitalized names. What makes them so special?"

As far as I can see, this question is never fully answered.

After some experimentation, these constructors seem to be precisely functions, with partial application, map, etc working as expected. But, for instance, (only) pattern matching works on constructed values, so maybe there is something special about them?

It would be good to get some clarification on this.
rtfeldman (60) [Avatar] Offline
Yep, that's the answer - pattern matching is the only thing that makes them special compared to other functions.

I'll try to find a way to clarify this. Thanks for the feedback!