[Haskell] Haskell Weekly News: Issue 170
Daniel Santa Cruz
dstcruz at gmail.com
Thu Feb 24 06:29:33 CET 2011
Welcome to issue 170 of the HWN, a newsletter covering developments in
the [1]Haskell community. This release covers the week of February 13 -
19, 2011.
Announcements
Simon Michael [2]informed us of reviving of FunGEn as a community
project. "FunGEn (Functional Game Engine) is a platform-independent,
BSD-licensed, easy-to-install 2D game engine currently based on OpenGL
and GLUT."
Alexander McPhail [3]announced the release of vector-buffer. "It
provides a buffer that can be turned into a Data.Vector.Storable. The
mapM* functions map from the oldest element, not the first."
Mark P. Jones [4]announce the availability of 2 openings for
post-doctoral researches "to help design, develop, and apply a new
strongly typed, pure functional language for systems programming."
Trystan Spangler [5]made a second release of his Behavior Driven
Development for Haskell, and the tool can now be found in Hackage!
Jeremy Shaw [6]announce the release of Happstack 6. "We fully recomend
that all Happstack users migrate to the new release."
Gregory D. Weber [7]published a new release of Sifflet and sifflet-lib.
"Sifflet is a visual, functional programming language and support
system for students learning about recursion."
Johan Tibell [8]announced the release of two new packages:
unordered-containers (Efficient hashing-based container types), and
hashable (Efficient hashing of common types).
Quotes of the Week
* kmc: i started to read the "tutorial" and it was incomprehensible.
makes the Gentle Introduction to Haskell look like Teach Yourself
PHP in 24 Hours
* ConorMcBride: Sometimes it's easier to search for good programs in
the space of well typed programs, rather than in the space of ascii
turds.
* monochrom: best practice haskell is "go with your heart"
* accel: one day, it was raining -- I was walking home -- I saw Knuth
biking home, wearing a helmet, in the rain -- and I freaked out --
rain was hitting him like any other mortal ... it wasn't bounching
off his aura of awesomeness
Top Reddit Stories
* Type level natural numbers ... ready to merge into GHC mainline:
From (hackage.haskell.org), scored 62 with 44 comments. Read on
[9]reddit or the [10]original post.
* Haskell Web Framework Happstack 6 Released: From
(groups.google.com), scored 45 with 3 comments. Read on [11]reddit
or the [12]original post.
* Well-Typed is hiring: From (well-typed.com), scored 41 with 13
comments. Read on [13]reddit or the [14]original post.
* Haskell is Better: slides from Mark Lentczner's talk at Ignite
Silicon Valley: From (scribd.com), scored 40 with 43 comments. Read
on [15]reddit or the [16]original post.
* New, faster hashing-based containers library released: From
(blog.johantibell.com), scored 40 with 6 comments. Read on
[17]reddit or the [18]original post.
* Disciple haskell dialect : strict evaluation as default ,
destructive update of data structures.: From
(disciple.ouroborus.net), scored 35 with 25 comments. Read on
[19]reddit or the [20]original post.
* Yesod: Warp Speed Ahead: From (docs.yesodweb.com), scored 34 with 8
comments. Read on [21]reddit or the [22]original post.
* Faster persistent data structures through hashing: From
(blog.johantibell.com), scored 28 with 15 comments. Read on
[23]reddit or the [24]original post.
* Developing iPhone applications in Haskell â a tutorial: From
(gergo.erdi.hu), scored 25 with 6 comments. Read on [25]reddit or
the [26]original post.
* An Introduction to Agda :: PDF: From (dl.dropbox.com), scored 24
with 4 comments. Read on [27]reddit or the [28]original post.
Top StackOverflow Answers
* [29]How to tell whether Haskell will cache a result or recompute
it? votes: 17
primes, in your code, is not a function, but a constant, in
haskellspeak known as a CAF. If it would take a parameter
(say, ()), you would get two different versions of the same
list back if calling it twice, but as it is a CAF, you get the
exact same list back both times;
As a top-level definition, primes never gets out of scope,
thus the head of the list ...
* [30]Specific type inference using uncurry function votes: 17
This has nothing to do with ghci. This is the monomorphism
restriction being irritating. If you try to compile the following file:
add = uncurry (+)
main = do
print $ add (1,2 :: Int)
print $ add (1,2 :: Double)
You will get an error. If you expand:
main = do
print $ uncurry (+) (1,2 :: Int)
print $ uncurry (+) (1,2 :: Double)
...
* [31]Haskell: Unexpected output for expression [0, 0.1 .. 1]
votes: 15
This is a result of the imprecision of floating point values,
it isn't particular to Haskell. If you can't deal with the
approximation inherent in floating point then you can use
Rational at a high performance cost:
> import Data.Ratio
Data.Ratio> [0,1%10.. 1%1]
[0 % 1,1 % 10,1 % 5,3 % 10,2 % 5,1 % 2,3 % 5,7 % 10,4 % 5,9 % 10,1 % 1]
Just to hammer ...
* [32]valid haskell function names votes: 14
From the Haskell report:
Haskell uses the Unicode character set. However, source programs are
currently biased toward the ASCII character set used in earlier
versions of Haskell. Recent versions of GHC seem to be fine with
unicode (at least in the form of UTF-8):...
* [33]Haskell range notation to generate list. Unexpected output
votes: 13
The notation is meant to mimic the usual way to write simple
sequences mathematics. The second element is not the step, but
in fact the actual second element of the list. The rest is
linearly extrapolated from there. Examples:
[1,2..10] = [1,2,3,4,5,6,7,8,9,10]
[1,3..10] = [1,3,5,7,9]
[4,3..0] = [4,3,2,1,0]
[0,5..] = [0,5,10,15,20,25,30,35...
Top StackOverflow Questions
* How to tell whether Haskell will cache a result or recompute it?
(votes: 11, answers: 1) [34]read
* How can one distribute Haskell programs to non-technical end users?
(votes: 8, answers: 2) [35]read
* Haskell range notation to generate list. Unexpected output (votes:
8, answers: 2) [36]read
* Appropriate uses of Monad `fail` vs. MonadPlus `mzero` (votes: 8,
answers: 2) [37]read
* Why does Haskell not have an I Monad (for input only, unlike the IO
monad)? (votes: 8, answers: 3) [38]read
About the Haskell Weekly News
To help create new editions of this newsletter, please send stories to
dstcruz at gmail.com.
Until next time,
Daniel Santa Cruz
References
1. http://haskell.org/
2. http://permalink.gmane.org/gmane.comp.lang.haskell.cafe/86330
3. http://permalink.gmane.org/gmane.comp.lang.haskell.cafe/86371
4. http://www.haskell.org/pipermail/haskell/2011-February/022585.html
5. http://permalink.gmane.org/gmane.comp.lang.haskell.general/18510
6. http://www.mail-archive.com/haskell-cafe@haskell.org/msg87352.html
7. http://www.mail-archive.com/haskell@haskell.org/msg23319.html
8. http://article.gmane.org/gmane.comp.lang.haskell.general/18515
9. http://www.reddit.com/r/haskell/comments/fnc80/type_level_natural_numbers_ready_to_merge_into/
10. http://hackage.haskell.org/trac/ghc/ticket/4385
11. http://www.reddit.com/r/haskell/comments/fnit9/haskell_web_framework_happstack_6_released/
12. http://groups.google.com/group/happs/browse_thread/thread/f72d7ff313ea9fa0
13. http://www.reddit.com/r/haskell/comments/flyyg/welltyped_is_hiring/
14. http://www.well-typed.com/blog/50
15. http://www.reddit.com/r/haskell/comments/flajs/haskell_is_better_slides_from_mark_lentczners/
16. http://www.scribd.com/doc/48773692/Ignite-SV-Haskell-is-Better
17. http://www.reddit.com/r/haskell/comments/fo9gm/new_faster_hashingbased_containers_library/
18. http://blog.johantibell.com/2011/02/new-faster-containers-library.html
19. http://www.reddit.com/r/haskell/comments/fojb4/disciple_haskell_dialect_strict_evaluation_as/
20. http://disciple.ouroborus.net/
21. http://www.reddit.com/r/haskell/comments/flp87/yesod_warp_speed_ahead/
22. http://docs.yesodweb.com/blog/warp-speed-ahead
23. http://www.reddit.com/r/haskell/comments/fm6gg/faster_persistent_data_structures_through_hashing/
24. http://blog.johantibell.com/2011/02/slides-from-my-hashing-based-containers.html
25. http://www.reddit.com/r/haskell/comments/fkqe1/developing_iphone_applications_in_haskell_a/
26. http://gergo.erdi.hu/blog/2011-02-13-developing_iphone_applications_in_haskell___a_tutorial/
27. http://www.reddit.com/r/haskell/comments/fl0wr/an_introduction_to_agda_pdf/
28. http://dl.dropbox.com/u/361503/Agda%20and%20dependent%20types.pdf
29. http://stackoverflow.com/questions/5032750/how-to-tell-whether-haskell-will-cache-a-result-or-recompute-it/5032920#5032920
30. http://stackoverflow.com/questions/4999020/specific-type-inference-using-uncurry-function/4999860#4999860
31. http://stackoverflow.com/questions/5048920/haskell-unexpected-output-for-expression-0-0-1-1/5048970#5048970
32. http://stackoverflow.com/questions/5023485/valid-haskell-function-names/5023519#5023519
33. http://stackoverflow.com/questions/5012185/haskell-range-notation-to-generate-list-unexpected-output/5012276#5012276
34. http://stackoverflow.com/questions/5032750/how-to-tell-whether-haskell-will-cache-a-result-or-recompute-it
35. http://stackoverflow.com/questions/5004902/how-can-one-distribute-haskell-programs-to-non-technical-end-users
36. http://stackoverflow.com/questions/5012185/haskell-range-notation-to-generate-list-unexpected-output
37. http://stackoverflow.com/questions/5023969/appropriate-uses-of-monad-fail-vs-monadplus-mzero
38. http://stackoverflow.com/questions/5032475/why-does-haskell-not-have-an-i-monad-for-input-only-unlike-the-io-monad
More information about the Haskell
mailing list