Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Haskell
Wiki community
Recent changes
Random page
HaskellWiki
Search
Search
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
Talk:Typeclassopedia
(section)
Add topic
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
Add topic
View history
General
What links here
Related changes
Special pages
Page information
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== Β§6.4 Other monoidal classes == This section states that instances of Alternative/MonadPlus/ArrowPlus are sometimes the same as the Monoid instance, and sometimes different. It would be helpful (imo) if it was explained why this is: whether it would be better if instances of Alternative/MonadPlus/ArrowPlus were the same as the Monoid instance, and that sometimes they are not due to accidents of history; or whether sometimes these instances should be different, and giving guidance as to when those times are. --[[User:Dave4420|Dave4420]] 17:16, 26 November 2011 (UTC) Hmm, where does it say that? [[User:Byorgey|Byorgey]] 17:40, 26 November 2011 (UTC) Search for <blockquote>A simple example of a <code>MonadPlus</code> instance is <code>[]</code>, which is exactly the same as the <code>Monoid</code> instance for <code>[]</code>: the empty list represents failure, and list concatenation represents choice. In general, however, a <code>MonadPlus</code> instance for a type need not be the same as its <code>Monoid</code> instance; <code>Maybe</code> is an example of such a type.</blockquote>--[[User:Dave4420|Dave4420]] 09:54, 27 November 2011 (UTC) :Ah, I see now. I think it's mostly due to history. Many of these types could have many different <code>Monoid</code> instances. I'll put in some additional discussion. --[[User:Byorgey|Byorgey]] 03:44, 28 November 2011 (UTC)
Summary:
Please note that all contributions to HaskellWiki are considered to be released under simple permissive license (see
HaskellWiki:Copyrights
for details). If you don't want your writing to be edited mercilessly and redistributed at will, then don't submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource.
DO NOT SUBMIT COPYRIGHTED WORK WITHOUT PERMISSION!
Cancel
Editing help
(opens in new window)
Toggle limited content width