| Register | FAQ | Calendar | Search | Today's Posts | Mark Forums Read |
|
#1
| |||
| |||
| 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. scala is sorta offering headway with its immutable collections, i guess, but overall the language has no guarantees or checks enforcing proper control over mutability. it is all up to people being on their best behaviour and not making any mistakes ever -- not an ideal situation imho. gracias. p.s. unfortunately i'm not anywhere remotely programming-language- theory enough to ever work on my own language. so i'm just nothing more than the peanut gallery. |
|
#2
| |||
| |||
| raould <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 |
|
#3
| |||
| |||
| > 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. |
|
#4
| |||
| |||
| 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 |
![]() |
| Thread Tools | |
| Display Modes | |
In an effort to better serve ads to our visitors, cookies are used on objectmix.com. For more information, check out our Privacy Policy.