nushio3 / Paraiso

a Parallel Integration Scheme Organizer for partial differential equations solvers
http://www.paraiso-lang.org/wiki/
BSD 3-Clause "New" or "Revised" License
49 stars 8 forks source link

make Annotation a Genuine Monoid #19

Closed nushio3 closed 12 years ago

nushio3 commented 12 years ago

Let Annotation satisfy Monoid laws in such manner that only leftmost Set survive when they are mappended.

nushio3 commented 12 years ago

If we use monoidness in addNodeE, then we need to put around too many Monoid contexts. Instead, I'll specify default annotation as a context.

Annotation will need to be a monoid in the future when we actually plan to create Builders that add Annotations.

nushio3 commented 12 years ago

I guess it does not need to be a monoid, you can just accept a function that modifies the annotation.