successful mutation-controlled libraries+language?
  Home FAQ Contact Sign in
comp.lang.functional only
 
Advanced search
POPULAR GROUPS

more...

comp.lang.functional Profile…
 Up
successful mutation-controlled libraries+language?         


Author: raould
Date: Aug 20, 2008 11:39

anybody have an opinion on how to get a language + extensive libraries
that are careful about mutability a la monads / uniqueness / regions /
single assignment?

it seems really frustrating to me that we all know unconstrained
mutation is evil, and yet things like Java or .Net which don't
constrain it are "ahead" in the sense of having libraries to do pretty
much any darned thing you might want.

could do some code generation to wrapper Java or .Net libraries to
somehow make them immutable? yuck, no. presumably the performance
would kind of suck vs. structures defined from the get-go from the FP
immutable-copy-on-write-persistent-shared-sub-structures approach?
and, more important, it doesn't do you any good when it comes to
offering some reassurance that the 3rd party library you downloaded
isn't junky because it just uses mutability willy-nilly; it would be
preferable if everything in the ecosystem was fundamentally based on
the proper taming of mutation. greatly reduces that aspect of code
inspection / review responsibilities.
Show full article (1.50Kb)
3 Comments
Re: successful mutation-controlled libraries+language?         


Date: Aug 20, 2008 19:42

raould gmail.com> writes:
> anybody have an opinion on how to get a language + extensive libraries
> that are careful about mutability a la monads / uniqueness / regions /
> single assignment?

Disciple (a Haskell dialect with effect types) looks interesting:

http://www.haskell.org/haskellwiki/DDC
no comments
Re: successful mutation-controlled libraries+language?         


Author: raould
Date: Aug 21, 2008 12:09

> Disciple (a Haskell dialect with effect types) looks interesting:
> http://www.haskell.org/haskellwiki/DDC

absolutely. i can hope that it, or perhaps also something like BitC,
will grow up to be a bigger system with rich libraries and all that
useful ancillary ecosystem jazz.

hm. i guess if i had time or bucks, i'd try to get a floss project
going for immutable libraries on the jvm for any jvm language to use.

sincerely.
no comments
Re: successful mutation-controlled libraries+language?         


Author: Jon Harrop
Date: Aug 22, 2008 04:16

raould wrote:
> it seems really frustrating to me that we all know unconstrained
> mutation is evil, and yet things like Java or .Net which don't
> constrain it are "ahead" in the sense of having libraries to do pretty
> much any darned thing you might want.

I consider mutation to be essential for usable efficiency. Moreover, .NET is
a pioneering functional platform with first-class functions baked into the
Common Language Run-time, a variety of immutable data structures (e.g.
strings are immutable on .NET but mutable in OCaml!) and even
state-of-the-art libraries like Microsoft's Task Parallel Library that
bring parallelism using higher-order functions more effectively than
anything ever implemented in any functional language.

While the type systems of languages like OCaml and Haskell are
unquestionably advanced, even compared to F#, all of their implementations
are now outdated in many respects. Their inability to leverage multicores
being the single most important one.

--
Dr Jon D Harrop, Flying Frog Consultancy
http://www.ffconsultancy.com/products/?u
no comments