Re: [Haskell] [Haskell, FP] Anduril Industries is Hiring
Hi Travis, It would be helpful if you said a) where this was and b) if remote work is possible. On 5 April 2018 at 15:01, Travis Whitaker <tra...@anduril.com> wrote: > Anduril Industries (https://www.anduril.com) is hiring. TL;DR: Come write > Haskell, Rust, and Nix (and some C++ when necessary) to make autonomous > robots and drones go! > > We're a team of software and hardware engineers from various backgrounds > (game development, computer graphics, financial technology, government > intelligence, biotechnology) working to improve the state of defense > technology. Our strategy involves focusing on product development instead of > traditional governmental processes. By funding product development ourselves > instead of relying on government funds, we're able to create more focused > products faster and with significantly fewer resources. By leveraging > hardware and techniques that have only recently become feasible to deploy at > scale (e.g. GPGPU computing), we can significantly advance the state of the > defense technology market. > > We're searching for generally competent, mathematically inclined software > engineers, and we're especially interested in those with experience in > computer vision (first principles techniques and machine learning), sensor > fusion, detection and tracking, and statistical parameter estimation. Our > team is increasingly applying functional programming and related > technologies; we run Haskell and Rust code in production and use Nix to > achieve reproducible build environments and keep deployment, CI, and > cross-compilation sane. > > If you like functional programming, interfacing with hardware, and solving > problems in detection, tracking, and autonomous vehicle control (land and > air), drop me a line at tra...@anduril.com > > > ___ > Haskell mailing list > Haskell@haskell.org > http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell > -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell
[Haskell] ANNOUNCE: servant-pandoc 0.5.0.0
I'm pleased to announce the latest release of the servant-pandoc library: https://hackage.haskell.org/package/servant-pandoc-0.5.0.0 servant-pandoc allows you to take the documentation created with servant-docs and use Pandoc to convert it into whichever format you want (rather than the Markdown generated by servant-docs). The main changes in this release are to provide compatibility with servant-docs-0.11.1; specifically, servant-pandoc now emits all the information that servant-docs does with the same configuration options. As such, there are behavioural changes which necessitated the major version bump. -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell
[Haskell] ANNOUNCE: streaming-conduit
I've recently found myself really enjoying using Michael Thompson's [streaming] library for, well, streaming data. However, a lot of packages that I want to use already use conduit for all their streaming needs. As such, I've just written the [streaming-conduit] library to convert between the two (rather than just switching this project to conduit entirely as I couldn't find a simple way to just stream data from a PostgreSQL database). I make no guarantees at this stage of performance, and it's quite possible that - especially for the asStream and asConduit functions - that they may not interoperate cleanly with monadic operations. [streaming]: https://hackage.haskell.org/package/streaming [streaming-conduit]: https://hackage.haskell.org/package/streaming-conduit -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell
Re: [Haskell] Haskell Tools
Is there support for anything except Atom at this time? I'm also unsure of what I need to install on my local machine if I want to try it out (do I need the daemon? or is the cli tool sufficient?). On 6 April 2017 at 17:03, Boldizsár Németh <nbo...@caesar.elte.hu> wrote: > Dear Haskellers, > > I'm happy to announce a new tool for refactoring Haskell source code. > Check it out: http://haskelltools.org/ > > Best Regards, > Boldizsár Németh > ___ > Haskell mailing list > Haskell@haskell.org > http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell
Re: [Haskell] I repeat my Question becaue I not really sure to do it right
On 28 August 2016 at 22:40, <cc...@web.de> wrote: > This is Leksah http://leksah.org/ > Please excuse my false name for it > And the Question is why can I install it. What error messages do you have when you try? From here, this is what you need to do: https://github.com/leksah/leksah/wiki/download > cabal install gtk2hs-buildtools > cabal install leksah > > excuse me. > Mungo1981 > > Gesendet: Sonntag, 28. August 2016 um 13:49 Uhr > Von: "Ivan Lazar Miljenovic" <ivan.miljeno...@gmail.com> > An: cc...@web.de > Cc: "Haskell List" <haskell@haskell.org> > Betreff: Re: [Haskell] I repeat my Question becaue I not really sure to do > it right > On 28 August 2016 at 20:43, <cc...@web.de> wrote: >> Ok Haskell is good. >> Ok Laska is great. >> And my Ubuntu Studio ist rubish >> So I try to install Laska on Ubuntu Studio >> But when I do this, i will get a long list of dependecies >> which could not reallise >> So I not know what should I do > > Which question? > > What is Laska that you're having trouble installing it? > >> >> Mungo1981 >> >> _______ >> Haskell mailing list >> Haskell@haskell.org >> http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell >> > > > > -- > Ivan Lazar Miljenovic > ivan.miljeno...@gmail.com > http://IvanMiljenovic.wordpress.com > > ___ > Haskell mailing list > Haskell@haskell.org > http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell > -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell
Re: [Haskell] I repeat my Question becaue I not really sure to do it right
On 28 August 2016 at 20:43, <cc...@web.de> wrote: > Ok Haskell is good. > Ok Laska is great. > And my Ubuntu Studio ist rubish > So I try to install Laska on Ubuntu Studio > But when I do this, i will get a long list of dependecies > which could not reallise > So I not know what should I do Which question? What is Laska that you're having trouble installing it? > > Mungo1981 > > ___ > Haskell mailing list > Haskell@haskell.org > http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell > -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell
[Haskell] ANNOUNCE: testbench-0.1.0.0
I've just released a new library onto Hackage that aims to help you writing comparison-oriented benchmarks by: a) reducing the duplication found when using criterion directly b) let you test your benchmarked values/functions to ensure that they have the same result/satisfy a given predicate c) provide more comparison-oriented output I've written more about it here: https://ivanmiljenovic.wordpress.com/2016/05/23/test-your-benchmarks/ Or you could go straight to the Hackage page here: http://hackage.haskell.org/package/testbench -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell
[Haskell] ANNOUNCE: unordered-graphs
I have a relatively hacked-together graph library that uses unordered-containers as a backend available if anyone finds it interesting/useful: http://hackage.haskell.org/package/unordered-graphs It's primarily developed just for my own needs and thus I'm not sure how much future work I'll be doing on it, but I'm willing to accept pull requests. This library was semi-experimental in that I also tried a few things out with it: * Polymorphic node type * Fixed auto-generated edge type: this is because (node,node, label) triples (ala fgl) do not provide sufficient information to be able to distinguish between multiple edges, etc. * Type parameter to determine whether the graph is directed or undirected. * Typeclass to allow you to determine the type/output of a a match (I didn't end up actually using this, as the one time I needed to do a match I found the extra polymorphism caused problems; it also isn't comprehensive as I didn't write all that many instances.) -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell
[Haskell] ANNOUNCE: graphviz-2999.18.0.0
This is my "sorry it took so long" release: I'd like to apologise to all the people that have been nagging^W gently asking me when a GHC 7.10.*-compatible release would be available that it's taken me until now to do this, but I'm finally pleased to be able to say that you can now use my graphviz library to generate/parse Dot code and visualise graphs using the Graphviz suite of tools. As part of this version release, graphviz is now developed using git and can be found on GitHub: https://github.com/ivan-m/graphviz The major version bump is due to an extra attribute being made available, so in most (all?) cases you can safely version bump your existing dependencies. -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell
[Haskell] ANNOUNCE: fgl-5.5.2.0 and fgl-arbitrary-0.2.0.0
I'm pleased to announce that I've (finally!) just released version 5.5.2.0 of [fgl]. Major changes in this release include a test suite, refactorings, code clean-ups and the following potentially breaking changes (in that they were previously unspecified or incorrect): - `nodeRange` and `nodeRangeM` for the various graph data structures erroneously returned `(0,0)` for empty graphs (making them indistinguishable from graphs containing the single node `0`). They now match the default implementation of throwing an error. - The behaviour of `delLEdge` when dealing with multiple edges was unspecified; it now deletes only a single edge and the new function `delAllLEdge` deletes all edges matching the one provided. All changes can be found in the changelog. [fgl]: https://hackage.haskell.org/package/fgl Along with this I'm releasing version 0.2.0.0 of [fgl-arbitrary] (i.e. the I finally build against the version on Hackage release). [fgl-arbitrary]: https://hackage.haskell.org/package/fgl-arbitrary -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell
[Haskell] To all users of FGL
As you may now, for the past few months I've been (finally!) cleaning up FGL, adding tests, etc. One of the issues that has arisen with this is that the behaviour of the delLEdge [1] function is not well specified when dealing with multiple edges. Specifically, the documentation states that the purpose is to Remove *an* LEdge from the Graph. (emphasis added)... but the behaviour when dealing with multiple edges is to remove *all* such edges from the graph. The current version on GitHub is to instead just delete a single such labelled edge, with a new function delAllLEdge that replicates the current behaviour. Before releasing this change, however, I wanted to make sure that I wouldn't break people's code if they rely upon this functionality; I did try and search through GitHub to see who - if anyone - is using this function, but primarily found various copies of fgl embedded into other people's repositories. As such, please check your code and let me know if this change in behaviour might affect you (if this is the case, I might let delLEdge keep the current behaviour and have a new function delete just one edge). [1]: http://hackage.haskell.org/package/fgl-5.5.1.0/docs/Data-Graph-Inductive-Graph.html#v:delLEdge -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell
[Haskell] ANNOUNCE: fgl-arbitrary
I've just released the first version of fgl-arbitrary [1], which provides Arbitrary instances for fgl graphs for use with QuickCheck. Also provided are some wrapper newtypes to produce specific types of graphs, and also the ability to generate just valid node and edge lists for use with other graph-like data structures. [1]: http://hackage.haskell.org/package/fgl-arbitrary -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell
[Haskell] ANNOUNCE: fgl 5.5.1.0
I'm pleased to announce that - after being pestered about it for the past few months ;-) - I've released a new version of the Functional Graph Library that should* now be compatible with GHC 7.10. fgl is now developed on GitHub: https://github.com/haskell/fgl * In that I can't test it on my own machines -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell
[Haskell] ANNOUNCE: monad-levels
I'm pleased to announce the first release of my new monad-levels library (aka Yet Another Monad Transformer Library ;-) http://hackage.haskell.org/package/monad-levels I've written more about the motivations of the library here: https://ivanmiljenovic.wordpress.com/2015/02/02/monadic-yak-shaving/ -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell
Re: [Haskell] Drastic Prelude changes imminent
On 27 January 2015 at 21:52, Augustsson, Lennart lennart.augusts...@sc.com wrote: If you didn’t know that, e.g., the type of foldr is changing, check out the thread https://www.haskell.org/pipermail/libraries/2015-January/024777.html. This seems to refer to your previous message, with no actual thread present and no mention of what the type of foldr is changing *to* (or what all the other bridge-breaking is going to be); is there an actual list of what these changes are? This email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please delete all copies and notify the sender immediately. You may wish to refer to the incorporation details of Standard Chartered PLC, Standard Chartered Bank and their subsidiaries at http://www.standardchartered.com/en/incorporation-details.html Insofar as this communication contains any market commentary, the market commentary has been prepared by a sales and/or trading desk of Standard Chartered Bank or its affiliate. It is not and does not constitute research material, independent research, recommendation or financial advice. Any market commentary is for information purpose only and shall not be relied for any other purpose, and is subject to the relevant disclaimers available at http://wholesalebanking.standardchartered.com/en/utility/Pages/d-mkt.aspx. Please visit http://wholesalebanking.standardchartered.com/en/capabilities/financialmarkets/Pages/doddfrankdisclosures.aspx for important information with respect to derivative products. ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell
[Haskell] ANNOUNCE: buildable-0.1.0.0
Have you ever wanted to deal with the builders for various data types in a polymorphic/overloaded fashion? I'm needing to do so and couldn't find any existing code that did so, so I decided to rectify this: http://hackage.haskell.org/package/buildable As a (very contrived) example: λ build ((365 :: Dec Int) | fromValue (Char7 ' ') | (365 :: BigEndian Int16) | ( omega=ퟂ :: Utf8 String) | Utf16 (LE (hello :: LT.Text))) :: SB.ByteString 365 \SOHm omega=\240\157\159\130 h\NULe\NULl\NULl\NULo\NUL -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell
[Haskell] ANNOUNCE: graphviz-2999.17.0.0
It's taken me over a year, but I'm pleased to announce the latest version of my graph visualisation (via the Graphviz suite of tools) library: http://hackage.haskell.org/package/graphviz You can read all the changes in the Changelog (now linked to from the Hackage page, thanks to the magic of Hackage 2.0! :o), but here are some explicit non-API changes that people should probably be made aware of: * Parsing is currently about 8x slower than previously... because I suggested something two years ago to Malcolm Wallace on what seemed to make polyparse faster; he then released that change as part of polyparse-1.9 a year ago, but now when I do proper benchmarks (rather than the extremely limited ones I did then) I find that my changes actually make it _slower_ in real world usage. Whoops! I'm still using polyparse-1.9 in the hopes that Malcolm is able to release a point-fix release to revert my suggestion. * I'm not sure when it happened, but upstream Graphviz seems to have changed the behaviour of `dot -Tcanon` such that nodes are now interspersed among the edges (and I have been told that it's just a pretty-printer and that it's behaviour should not matter). As such, it is highly recommended that people only use the Generalised representation for parsing unless they're very sure of their input sources. One other change that people might find useful: if I ever again take so long (i.e. 4 major version releases of upstream) to update graphviz such that the various Attribute definitions are no longer valid and fail to parse, there's now (semi-experimental) support for having unrecognised attributes be parsed as an UnknownAttribute instead; but most of the other functions aren't aware of this functionality and thus you might need to duplicate a lot of code if you want to use this with other features like round-tripping. -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell
[Haskell] ANNOUNCE: fgl-5.5.0.0
I'm pleased to announce a new version of the functional graph library: http://hackage.haskell.org/package/fgl-5.5.0.0 The main change in this version: proper Show, Read and Eq instances for both graph implementations. Previously, Data.Graph.Inductive.Tree had a pretty-printed Show output; now both it and PatriciaTree have Show and Read instances via the mkGraph function, and Eq via deriving (I'm not sure how well this will work because as I write this I realise it may not deal with multiple edges that well... I guess I'll be doing an updated version tomorrow after getting some sleep ;p). The previous Show behaviour of Tree is now available as a pretty-printing function for all DynGraph instances. The PatriciaTree implementation is now exported and used by default, because as far as I'm aware it will always perform better. Finally, the Data.Graph.Inductive.Graphviz module has been removed; if you want to visualise your fgl graph, please see my graphviz package on Hackage (cheap plug? moi?). -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell
Re: [Haskell-cafe] cabal: internal error when reading package index
On 18 September 2013 19:23, Henk-Jan van Tuyl hjgt...@chello.nl wrote: L.S., I was trying to install a package from a local drive and got the following message: cabal install Resolving dependencies... cabal: internal error when reading package index: could not read tar file entryThe package index or index cache is probably corrupt. Running cabal update might fix it. Then I tried cabal update: cabal update Downloading the latest package list from hackage.haskell.org Skipping download: Local and remote files match. Note: there is a new version of cabal-install available. To upgrade, run: cabal install cabal-install Trying the command cabal install cabal-install gave the same internal error message as for the first command. What can I do about this? Maybe try deleting the current download? Namely ~/.cabal/packages/hackage.haskell.org/00-index.* Regards, Henk-Jan van Tuyl -- Folding@home What if you could share your unused computer power to help find a cure? In just 5 minutes you can join the world's biggest networked computer and get us closer sooner. Watch the video. http://folding.stanford.edu/ http://Van.Tuyl.eu/ http://members.chello.nl/hjgtuyl/tourdemonad.html Haskell programming -- ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Proposal: Pragma EXPORT
On 17 September 2013 09:35, Evan Laforge qdun...@gmail.com wrote: On Mon, Sep 16, 2013 at 4:09 PM, Wvv vite...@rambler.ru wrote: I suggest to add instead of (or with) export section Pragma EXPORT: I doubt this has much chance, since haskell already made its choice here a long time ago (and even if it were still up for discussion, PRAGMA isn't right for it), but this brings up a design question I've had. I too prefer to declare visibility on the declaration rather than in a separate list. C doesn't really have a proper module system, but header files are effectively a separate module signature. C++ and Java and go preferred to mark visibility on the declaration. The ML family keeps visibility and declarations separate, which is where I assume haskell got it (that or maybe modula?). In the case of the MLs, though, it's a much more developed concept, since they have module signatures and functors and all that. In light of haskell's very basic module system, is there any particular philosophical reason to prefer a separate export list? Or are those who prefer it for practical reasons? The only thing I can think of is that it provides a nice summary of the module, which haddock capitalizes on. But when I want a summary, I look at haddock, which would already be capable of hiding internal definitions. I have heard that haskell's module system was originally intended as a kind of simple-as-possible placeholder (like records... cough cough), maybe the designers though an ML-style module system might eventually materialize? To me it's always been a hassle to have to jump to the top of the file and fiddle with the export list, so much so that I tend to leave it off until a module is pretty stabilized. It can also be confusing when the export list is in a different order from the declarations. Sometimes I want to explicitly mark something private, and simply doesn't happen to be in the export list is too implicit, so I wind up putting a _ on it. None of this is a big deal, but I'm curious about other's opinions on it. Are there strengths to the separate export list that I'm missing? I do like the actual summary aspect as you've noted, as I can at times be looking through the actual code rather than haddock documentation when exploring new code (or even trying to remember what I wrote in old code). It also makes actual definitions cleaner/shorter rather than cluttering them with extra annotations (either PRAGMAs or public/private markers), though this is not that big of a deal. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] typeclass constraints
On 23 August 2013 19:23, TP paratribulati...@free.fr wrote: Hi everybody, There is something I do not understand in the way typeclass constraints are inferred. 1/ Take the following function definition: sum' [] = [] sum' (x:xs) = x + sum' xs You haven't specified a type signature here, so GHC will derive the most generic one possible. GHCI correctly gives: :t sum' sum' :: Num [a] = [[a]] - [a] So it has inferred that the type list has to be an instance of Num for sum' to be able to work. It will give an error if we try to use sum' without implementing the instance. 2/ Now, take the following definition: {-# LANGUAGE TemplateHaskell #-} import Language.Haskell.TH import Language.Haskell.TH.Syntax p :: a - ExpQ p n = [| show n |] You have defined a type signature here, so GHC will try to use it... except (as you've noted) GHC will then complain that it's wrong. If GHC auto-magically fixed incorrect type signatures, then one of the major advantages of the type system (i.e. specify a type for a function and then use that to guarantee that the function matches the specification of what we wanted) will no longer be valid. We obtain an error if we try to load it in GHCI: No instance for (Lift a) arising from a use of `n' Possible fix: add (Lift a) to the context of the type signature for p :: a - ExpQ In the first argument of `show', namely `n' In the Template Haskell quotation [| show n |] In the expression: [| show n |] And indeed, if we use instead: {-# LANGUAGE TemplateHaskell #-} import Language.Haskell.TH import Language.Haskell.TH.Syntax p :: Lift a = a - ExpQ p n = [| show n |] it works correctly. Why GHC is able to infer the typeclass constraint (Num a) in 1/, but not (Lift a) in 2/? Thanks in advance, TP ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] One-element tuple
On 20 August 2013 11:07, AntC anthony_clay...@clear.net.nz wrote: Daniel F difrumin at gmail.com writes: Can you please elaborate why this inconsistency is annoying and what's the use of OneTuple? Genuine question, Hi Daniel, the main annoyance is the verbosity (of using a data type and constructor), and that it no longer looks like a tuple. The inconsistency is because a one-element tuple is just as cromulent as a n-element, or a zero-element. (And that a one-element tuple is a distinct type from the element on its own/un-tupled.) Why is it as cromulent (especially as I'm not so sure we could really consider () to be merely a zero-element tuple)? I can see what you're trying to do here, but for general usage isn't a single element tuple isomorphic to just that element (which is what newtypes are for if you need that distinction)? So if I have instances (as I do) like: instance C (a, b) ... instance C () ... I can't usefully put either of these next two, because they're equiv to the third: instance C (( a )) ... instance C ( a ) ... instance C a ... -- overlaps every instance Similarly for patterns and expressions, the so-called superfluous parens are just stripped away, so equivalent to the bare term. The use of OneTuple is that it comes with all Prelude instances pre- declared (just like all other tuple constructors). I don't see that it has an advantage over declaring your own data type(?) I'd also be interested to know who is using it, and why. As far as I'm aware, it's just a joke package, but two packages dealing with tuples seem to use it: http://packdeps.haskellers.com/reverse/OneTuple What I'm doing is building Type-Indexed Tuples [1] mentioned in HList [2], as an approach to extensible records [3], on the model of Trex [4] -- all of which acknowledge one-element records/rows/tuples. And then I'm using the tuples as a platform for relational algebra [5] with natural Join (and ideas from Tropashko's 'Relational Lattice' [6]). Is there anybody using OneTuple 'in anger'? AntC [1] M. Shields and E.Meijer. Type-indexed rows. In Proceedings of the 28th ACM SIGPLAN-SIGACT symposium on Principles of Programming Languages, pages 261–275. ACMPress, 2001. [2] http://hackage.haskell.org/package/HList [3] http://www.haskell.org/haskellwiki/Extensible_record [4] http://web.cecs.pdx.edu/~mpj/pubs/polyrec.html [5] http://en.wikipedia.org/wiki/Relational_algebra#Natural_join_ [6] http://vadimtropashko.wordpress.com/relational-lattice/ On Fri, Aug 16, 2013 at 5:35 AM, AntC anthony_clayden at clear.net.nz wrote: There's an annoying inconsistency: (CustId 47, CustName Fred, Gender Male) -- threeple (CustId 47, CustName Fred)-- twople -- (CustId 47)-- oneple not! () -- nople ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] inv f g = f . g . f
On 17 August 2013 19:11, Christopher Done chrisd...@gmail.com wrote: Anyone ever needed this? Me and John Wiegley were discussing a decent name for it, John suggested inv as in involution. E.g. In terms of a decent name: as soon as I saw the subject, I thought you were somehow inverting a function :/ In terms of how useful it is, I don't think I tend to use such an idiom. inv reverse (take 10) inv reverse (dropWhile isDigit) trim = inv reverse (dropWhile isSpace) . dropWhile isSpace That seems to be the only use-case I've ever come across. There's also this one: co f g = f g . g which means you can write trim = co (inv reverse) (dropWhile isSpace) but that's optimizing an ever rarer use-case. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] One-element tuple
On 16 August 2013 11:35, AntC anthony_clay...@clear.net.nz wrote: There's an annoying inconsistency: (CustId 47, CustName Fred, Gender Male) -- threeple (CustId 47, CustName Fred)-- twople -- (CustId 47)-- oneple not! () -- nople (That is, it's annoying if you're trying to make typeclass instances for extensible/contractable tuples. Yes, I know I could use HLists.) I'm not happy with either approach I've tried: data Oneple a = Oneple a -- (or newtype) (Oneple $ CustId 47) -- too verbose type Oneple a = [a] [CustId 47] -- at least looks bracket-y What do you do? http://hackage.haskell.org/package/OneTuple :p If you really wanted some form of parentheses you could possibly use quasiquoting for it... AntC ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] ordNub
On 16 July 2013 11:46, John Lato jwl...@gmail.com wrote: In my tests, using unordered-containers was slightly slower than using Ord, although as the number of repeated elements grows unordered-containers appears to have an advantage. I'm sure the relative costs of comparison vs hashing would affect this also. But both are dramatically better than the current nub. Has anyone looked at Bart's patches to see how difficult it would be to apply them (or re-write them)? If I understand correctly, this function is proposed to be added to Data.List which lives in base... but the proposals here are about using either Sets from containers or HashSet from unordered-containers; I thought base wasn't supposed to depend on any other package :/ On Mon, Jul 15, 2013 at 8:43 PM, Clark Gaebel cgae...@uwaterloo.ca wrote: Apologies. I was being lazy. Here's a stable version: import qualified Data.HashSet as S hashNub :: (Ord a) = [a] - [a] hashNub l = go S.empty l where go _ [] = [] go s (x:xs) = if x `S.member` s then go s xs else x : go (S.insert x s) xs Which, again, will probably be faster than the one using Ord, and I can't think of any cases where I'd want the one using Ord instead. I may just not be creative enough, though. - Clark On Mon, Jul 15, 2013 at 12:46 AM, Brandon Allbery allber...@gmail.com wrote: On Sun, Jul 14, 2013 at 7:54 AM, Clark Gaebel cgae...@uwaterloo.ca wrote: Oops sorry I guess my point wasn't clear. Why ord based when hashable is faster? Then there's no reason this has to be in base, it can just be a Did the point about stable fly overhead? -- brandon s allbery kf8nh sine nomine associates allber...@gmail.com ballb...@sinenomine.net unix, openafs, kerberos, infrastructure, xmonad http://sinenomine.net ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Why isn't hsc2hs functionality provided by ghc?
On 5 June 2013 17:34, Roman Cheplyaka r...@ro-che.info wrote: * Jason Dagit dag...@gmail.com [2013-06-04 21:00:25-0700] My preferred solution would be to have ghc/ghci automatically run hsc2hs (support c2hs also?) when necessary. But so long as it's handled automatically, I wouldn't be particularly bothered by the implementation. How about having a `ghci` command for cabal? Or does the automatic requirement really need to be part of ghc to work the way you want? (BTW, cabal-dev does have a `ghci` command, but I haven't tested to see if it does the hsc - hs conversion.) I don't think cabal can provide that. Let's say you're inside a 'cabal ghci' session. If you modify the hsc file and reload it in ghci, you'd expect to load the updated version — yet cabal hasn't even been called since 'cabal ghci', and have had no chance to re-generate the hs file. To answer the subject question — hsc2hs is not a single preprocessor available. There are also c2hs and greencard, and maybe something else. It is (or, at least, was) not clear which one should be generally preferred. Perhaps by now hsc2hs is a clear winner — I don't know. Another option is to add a generic preprocessor option to GHC, something like -pgmX cmd. Then, for hsc2hs one would write something like {-# OPTIONS_GHC -pgmX hsc2hs #-} Isn't this what -pgmF is for?http://www.haskell.org/ghc/docs/7.6.1/html/users_guide/options-phases.html#replacing-phases {-# OPTIONS_GHC -F -pgmF hsc2hs #-} This is a better option, IMO. Roman -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Why isn't hsc2hs functionality provided by ghc?
On 5 June 2013 12:02, silly silly8...@gmail.com wrote: I was wondering today, why hasn't hsc2hs been merged with ghc so that it would be possible to add a {-# LANGUAGE ForeignFunctionInterface #-} at the top of a source file and then load it with ghci or compile it, without the intermediate step of calling hsc2hs? This would be exactly like the CPP extension. I don't have to call cpp manually. All I have to do is to add {-# LANGUAGE CPP #-} and then ghc will take care of the rest. This would also mean that there would be no need to have a separate file extension. Surely I must not be the first person to have that thought, so there must be a good reason why this hasn't happen yet, but what is it? Isn't this done automatically when you have files with the .hsc extension? -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Hackage checking maintainership of packages
On 7 May 2013 17:36, Ilya Portnov port...@iportnov.ru wrote: Hi Cafe. I have thought that a more interesting metric might be to send the maintainer an email when their package stops building automatically on hackage. I think, this is must have feature for new hackage. If error was occured during build, send email to maintainer: Except that there are various reasons a package won't build on Hackage: * Temporary glitch with another Haskell dependency (e.g. package Foo depends upon Bar-x.*; maintainer of Bar uploads a new point release of Bar that fails to build just before Foo's maintainer uploads the new version, thus the build server picks the buggy version of Bar and thus the new version of Foo fails to build). * Requires a foreign library that isn't installed on the Hackage build server. * OS-dependent. -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Backward compatibility
On 3 May 2013 01:04, Brandon Allbery allber...@gmail.com wrote: On Thu, May 2, 2013 at 10:36 AM, Adrian May adrian.alexander@gmail.com wrote: I think you're missing the point of the platform! I suppose I did miss the point of the platform: I was trying to build it, which requires at least part of the Having to build it already indicates that something is wrong, unless you're porting to an unsupported OS/hardware. Or you have a source-based distro, or you prefer building it yourself rather than using distro packages (as they might be out of date or b0rked), etc. ... ;-) -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Markdown extension for Haddock as a GSoC project
On 29 April 2013 18:16, Alexander Kjeldaas alexander.kjeld...@gmail.com wrote: I see the pluggable markup being pushed in this thread again. I just want to remind everybody that we currently have a flavor of a markup issue on github. The ghc source code uses literal haskell, and it does not work well on github. http://www.haskell.org/pipermail/ghc-devs/2013-April/001099.html Any markup that is not widely supported makes it harder for third parties to support and parse. The solution is *not* to reimplement github in haskell, but to standardize markup as much as possible. Pluggable markup makes the probability that a github-like service, IDEs and similar can make use of the documentation arbitrarily close to zero. If it's pluggable, doesn't it make the situation _worse_, as you choose a plug-in that works with one service but then fails for all the others? I think this is a bit of a non-issue: services like github should _not_ mark-up documentation (as you're going to have some kind of issue where it's rendered when you didn't expect it or vice-versa, thus making it different to read the actual code). I tend to agree with Richard, etc.: I'd rather either extend the existing Haddock mark-up or choose a sane markup language if we wish to replace/augment it (I use markup, but find a lot of its conventions appalling). Alexander On Mon, Apr 29, 2013 at 8:04 AM, Richard A. O'Keefe o...@cs.otago.ac.nz wrote: I should add that as a consumer of Haddock documentation I can testify that fancier styling (in whatever format) would be of little benefit to _me_. What I need is more plain text and more examples. To be perfectly honest, most of the time when looking at a Haddock page, I end up clicking on the Source button because there are things I need to know that are in the source but not the documentation. So I do agree that markup that doesn't get in the way of a _reader_ who is looking at the source code is an excellent thing. I say this as someone who had to read some Java today and ended up stuffing it through a comment stripper so that I could easily find what I needed to find. This thread is not about the visually lightweight aspect of Markdown. That's a good thing. No argument there. The thread is about how well documented the notation should be. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] version of containers fixed by template-haskell?
On 17 April 2013 18:10, Johannes Waldmann waldm...@imn.htwk-leipzig.de wrote: Is it still the case that It just doesn't work to have multiple versions of a wired-in package (cf. http://hackage.haskell.org/trac/ghc/ticket/5704 )? ghc-7.6.2 comes with containers-0.5.0.0 and template-haskell-2.8.0.0 . It seems I can upgrade to containers-0.5.2.1 and use it with no problems but not alongside template-haskell: template-haskell depends upon containers; as such, if you try and use a different version of containers whilst also using template-haskell you're going to run into the diamond dependency problem: http://www.well-typed.com/blog/9# ... changes: containers-0.5.0.0 - 0.5.2.1, Warning: The following packages are likely to be broken by the reinstalls: ... ghc-7.6.2 (Isn't it somewhat bold of cabal-install to offer to break ghc-7.6.2? like, this will completely hose the compiler?) That's bad, because I use containers everywhere, and I assume that 0.5.2.1 has some advantages (like, speed) over 0.5.0.0. - J.W. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] primitive operations in StateT
On 16 April 2013 15:56, Clark Gaebel cgae...@uwaterloo.ca wrote: The monad my code is currently written in is: type MC = MCT Identity -- where MCT is the monad transformer version of it. I have two options for threading state through this: MCT (ST s) a StateT s MC a The first option would work if I had some function with the signature MCT Identity a - MCT (ST s) a but I know of no such function, and the second one would work if I had some way of making StateT a member of PrimMonad. Can I see an example with 'lift'? You should just be able to use lift to convert any PrimMonad action into your MCT-based monad as long as MCT is an instance of the MonadTrans class. i.e. if `foo :: (PrimMonad m) = m a' and MCT is an instance of MonadTrans, then you can do `lift foo :: (PrimMonad m) = MCT m a', or `lift (lift foo) :: (PrimMonad m) = MCT (StateT s m) a'. As another option, I have an as-yet-unreleased library to let you avoid having to do lift . lift for PrimMonad-based actions: http://hub.darcs.net/ivanm/monad-prim - Clark On Tuesday, April 16, 2013, Ivan Lazar Miljenovic wrote: On 16 April 2013 15:04, Clark Gaebel cgae...@uwaterloo.ca wrote: Hi list! I want to use MVectors in a StateT monad transformer. How do I do that? StateT isn't a member of 'PrimMonad', and I have no idea how to make it one. You can use Control.Monad.Trans.lift to lift the PrimMonad operations to PrimMonad m = StateT s m Regards, - Clark ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] primitive operations in StateT
On 16 April 2013 15:04, Clark Gaebel cgae...@uwaterloo.ca wrote: Hi list! I want to use MVectors in a StateT monad transformer. How do I do that? StateT isn't a member of 'PrimMonad', and I have no idea how to make it one. You can use Control.Monad.Trans.lift to lift the PrimMonad operations to PrimMonad m = StateT s m Regards, - Clark ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Prolog-style patterns
On 8 April 2013 21:11, Jan Stolarek jan.stola...@p.lodz.pl wrote: Hi all, consider this simple reimplementation of 'elem' function: member :: Eq a = a - [a] - Bool member _ [] = False member y (x:xs) | x == y= True | otherwise = member y xs If Haskell allowed to write pattern matching similar to Prolog then we could write this function like this: member :: Eq a = a - [a] - Bool member _ [] = False member x (x:_) = True member x (_:xs) = member x xs The meaning of pattern in the second equation is match this equation if the first argument equals to head of the list. Many times I have found myself instinctively writing patterns in this way, only to get a compilation error. I was thinking about implementing language extension for GHC that would allow to write Prolog-style patterns. Would there be an interest in such an extension? Also, if I missed something obvious please let me know. My initial take on this is that such capabilities would be too easy to mis-use accidentally; e.g. refactoring and changing variable names, thus causing patterns to match when you don't mean them to. Janek ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] GSoC Project Proposal: Markdown support for Haddock
On 9 April 2013 05:08, MigMit miguelim...@yandex.ru wrote: Отправлено с iPad 08.04.2013, в 21:44, Evan Laforge qdun...@gmail.com написал(а): Can't we just add some features to haddock? No, we can't. At the very least we should FIX haddock before adding features. How specifically does haddock need to be fixed? There are a lot of ways to improve haddock a lot, and no one is doing them, so my impression is that haddock doesn't really have active maintainers. Adding a whole new backend seems risky, unless it results in new maintainers joining. For my personal bikeshed contribution, I would like to see haddock move in the way of fewer markup characters and rules, not more. Since haddock is not statically checked, the only way to find out if I put in an error is to run haddock and then visually inspect the output, unless of course it was a syntax error, in which case the error message is often not very good. I can easily haddock individual files since I have a custom build system, but I imagine cabal users would have to haddock the entire project every time. I regularly see haddock errors in released packages so I'm not the only one. There are lots of ways to improve haddock a lot. For example, better parse error messages. Make s smarter so they don't try to link things that are obviously not modules. Or complain if it's not a module. Or better, get rid of them entirely and use single quotes for that. And make single quotes work for non-imported symbols. Incremental support for cabal. Perhaps even deprecate @ and use ' for that too. One thing I think HTML got right is that there are only two characters that need to be quoted. Of course that's at the cost of all the markup being wordy, but the more you move in the markup-style DWIM the more little rules you have to remember. On Thu, Apr 4, 2013 at 6:00 PM, Johan Tibell johan.tib...@gmail.com wrote: Would it be too much to ask that a notation be used which has a formal syntax and a formal semantics? We will document our superset, sure. That's what others did as well. The point is using Markdown as the shared base. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] GSoC Project Proposal: Markdown support for Haddock
On 8 April 2013 07:12, Roman Cheplyaka r...@ro-che.info wrote: Looks like a bug in cpphs to me (CC'ing Malcolm). It should respect comments. E.g. GNU cpp strips C comments. Not quite: http://hackage.haskell.org/trac/ghc/ticket/4836 Roman * John MacFarlane j...@berkeley.edu [2013-04-05 16:04:32-0700] I like markdown and use it all the time. While I acknowledge the problems that have been pointed out, markdown has the advantage of being easily readable as it is in the source document, and not looking like markup. But I do want to point out one problem with markdown as a format for documentation in Haskell files. Consider: module MyModule {- # Introduction This is my module -} where import System.Environment main = getArgs = print Now try to compile with -cpp, and you'll get an error because of the '#' in column 1. '#' in column 1 is common in markdown (and even indispensible for level 3+ headers). One could work around this by disallowing level 3+ headers, by allowing the headers to be indented, or by introducing new setext-like syntax for level 3+ headers, but it is a problem for the idea of using a markdown SUPERset. John +++ dag.odenh...@gmail.com [Apr 05 13 21:59 ]: I forgot the mention the craziness with the *significant trailing whitespace*. On Fri, Apr 5, 2013 at 9:49 PM, [1]dag.odenh...@gmail.com [2]dag.odenh...@gmail.com wrote: Personally I think Markdown sucks, although perhaps less than Haddock markup. Still: * No document meta data * No code block meta data like language for syntax highlighting * No tables * No footnotes * HTML fallback is insecure * Confusing syntax (is it []() or ()[] for links?) * Syntax that gets in the way (maybe I don't want *stars* emphasized) * Above point leads to non-standard dialects like GitHub Markdown (no, GitHub doesn't use markdown) * Not extensible, leading to even more non-standard hacks and work-arounds (GitHub Markdown, Pandoc Markdown, other Markdown libraries have their own incompatible extensions) * Not well suited for web input (e.g. four-space indentation for code blocks), although not that important for Haddock An important thing to note here is that no, Markdown has *not* won because no one is actually using *Markdown*. They're using their own, custom and incompatible dialects. Only two of the above points apply to reStructuredText (web input and syntax getting in the way), and those particular points don't apply to Creole. Therefore I tend to advocate Creole for web applications and reStructuredText for documents. On Thu, Apr 4, 2013 at 6:49 PM, Johan Tibell [3]johan.tib...@gmail.com wrote: Hi all, Haddock's current markup language leaves something to be desired once you want to write more serious documentation (e.g. several paragraphs of introductory text at the top of the module doc). Several features are lacking (bold text, links that render as text instead of URLs, inline HTML). I suggest that we implement an alternative haddock syntax that's a superset of Markdown. It's a superset in the sense that we still want to support linkifying Haskell identifiers, etc. Modules that want to use the new syntax (which will probably be incompatible with the current syntax) can set: {-# HADDOCK Markdown #-} on top of the source file. Ticket: [4]http://trac.haskell.org/haddock/ticket/244 -- Johan ___ Haskell-Cafe mailing list [5]Haskell-Cafe@haskell.org [6]http://www.haskell.org/mailman/listinfo/haskell-cafe References 1. mailto:dag.odenh...@gmail.com 2. mailto:dag.odenh...@gmail.com 3. mailto:johan.tib...@gmail.com 4. http://trac.haskell.org/haddock/ticket/244 5. mailto:Haskell-Cafe@haskell.org 6. http://www.haskell.org/mailman/listinfo/haskell-cafe ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] GSoC Project Proposal: Markdown support for Haddock
On 5 April 2013 13:24, Richard A. O'Keefe o...@cs.otago.ac.nz wrote: On 5/04/2013, at 2:00 PM, Johan Tibell wrote: Would it be too much to ask that a notation be used which has a formal syntax and a formal semantics? We will document our superset, sure. That's what others did as well. The point is using Markdown as the shared base. Nononono. Sure, the others documented their supersets. But they did *NOT* provide what I am asking for: - a FORMAL SYNTAX and - a FORMAL SEMANTICS. I tried to use one of these systems, and found myself unable to determine which combinations of features were legal and what legal combinations of features *meant*. I corresponded with some people who had built markdown parsers, and the answer was the same each time: they had reversed engineered some other parser (typically a Perl one) and bashed on it until they were bug-compatible. If I want to get a particular effect in LaTeX or even in HTML+CSS, I can usually figure it out *without* having to run any program. If I want to get a particular effect in Markdown, I flounder around and end up doing without. I am sick of documentation that vaguely hints at things, and I am especially sick of Markdown so-called documentation. To say it one more time: I was unable to use the official Markdown documentation, http://daringfireball.net/projects/markdown/syntax, to guide the construction of a parser. For example, br is a valid URL enclosed in . . ., so is it a link, as the Automatic Links section would suggest, or is it embedded HTML, as the Inline HTML section would suggest? Can you tell *from the documentation*? For another example, is *foo**bar**ugh* supposed to map to emfoostrongbar/strongugh/em or to emfoo/emembar/ememugh/em? Again, I'm not asking what does this or that *program* do, I'm asking can you tell from the documentation what they *ought* to do? If there is an unambiguous specification of Markdown somewhere (specification; not program), I would be glad to see it. I don't think so; this was one of the big issues recently when people were trying to get Gruber to actually _do_ something with Markdown as there were all these corner cases. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] GSoC Project Proposal: Markdown support for Haddock
On 5 April 2013 15:49, Kim-Ee Yeoh k...@atamo.com wrote: On Fri, Apr 5, 2013 at 10:44 AM, Ivan Lazar Miljenovic ivan.miljeno...@gmail.com wrote: I don't think so; this was one of the big issues recently when people were trying to get Gruber to actually _do_ something with Markdown as there were all these corner cases. In that case, surely this is an opportunity to convene a committee (a la H98) to craft a formal spec? There have been calls for such a committee: http://www.codinghorror.com/blog/2012/10/the-future-of-markdown.html -- Kim-Ee -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] [extension]syntactic sugar for maps
On 28 March 2013 06:30, Răzvan Rotaru razvan.rot...@gmail.com wrote: Hi, I am terribly missing some syntactic sugar for maps (associative data structures) in Haskell. I find myself using them more than any other data structure, and I think there is no big deal in adding some sugar for this to the language. I could not find out whether such an extension is beeing discussed. If not, I would like to propose and extension. Any help and suggestions are very welcome here. Thanks. What kind of syntactic sugar are you wanting? Also related to the topic: 1/ Is there a list of proposals for extensions to Haskell that has currently been accepted in the new standard? I have not found one on Haskell' (http://hackage.haskell.org/trac/haskell-prime/query?status=newstatus=assignedstatus=reopenedgroup=state), but it looks outdated. No mentions to the new standard! 2/ I have seen somewhere a statement that a new language standard will be published yearly. Didn't happen until now. Is there even a new standard on the way? Cheers, Răzvan ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Data.StorableVector vs Data.Vector.Storable
On 25 March 2013 05:04, Roman Cheplyaka r...@ro-che.info wrote: What is the relationship between these two modules? Do we really need both? There doesn't seem to be any relationship at all between them... (Data.Vector.Storable is part of vector, Data.StorableVector is from a separate package, storablevector.) Going by the initial release date for the two of them, storablevector is a few months older than vector. Otherwise, it's just like why we have multiple implementations of monad transformer stacks, etc. Roman ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Extracting exposed modules from an installed library
On 21 March 2013 19:52, Corentin Dupont corentin.dup...@gmail.com wrote: Hi Joachim, that's right thanks, but I was looking for a way to do that from a program. ghc-pkg does not seems to expose any library... http://hackage.haskell.org/packages/archive/Cabal/1.16.0.3/doc/html/Distribution-InstalledPackageInfo.html#t:InstalledPackageInfo_ ? On Wed, Mar 20, 2013 at 11:23 PM, Joachim Breitner m...@joachim-breitner.de wrote: Hi, Am Mittwoch, den 20.03.2013, 00:34 +0100 schrieb Corentin Dupont: Hi Cafe! I'm looking for how to extract the exposed modules (as a list of strings) from an installed library, giving the library name. I can see some structures in Cabal (InstalledPackageInfo) and some functions in ghc-pkg.hs in GHC, but nothing readily useable... $ ghc-pkg field base exposed-modules exposed-modules: Foreign.Concurrent GHC.Arr GHC.Base GHC.Char GHC.Conc GHC.Conc.IO GHC.Conc.Signal GHC.Conc.Sync GHC.ConsoleHandler GHC.Constants GHC.Desugar GHC.Enum GHC.Environment GHC.Err GHC.Exception GHC.Exts GHC.Fingerprint GHC.Fingerprint.Type GHC.Float GHC.Float.ConversionUtils GHC.Float.RealFracMethods GHC.Foreign GHC.ForeignPtr GHC.Generics GHC.GHCi GHC.Handle GHC.IO GHC.IO.Buffer GHC.IO.BufferedIO GHC.IO.Device GHC.IO.Encoding GHC.IO.Encoding.CodePage GHC.IO.Encoding.Failure GHC.IO.Encoding.Iconv GHC.IO.Encoding.Latin1 GHC.IO.Encoding.Types GHC.IO.Encoding.UTF16 GHC.IO.Encoding.UTF32 GHC.IO.Encoding.UTF8 GHC.IO.Exception GHC.IO.FD GHC.IO.Handle GHC.IO.Handle.FD GHC.IO.Handle.Internals GHC.IO.Handle.Text GHC.IO.Handle.Types GHC.IO.IOMode GHC.IOArray GHC.IOBase GHC.IORef GHC.IP GHC.Int GHC.List GHC.MVar GHC.Num GHC.PArr GHC.Pack GHC.Ptr GHC.Read GHC.Real GHC.ST GHC.Stack GHC.Stats GHC.Show GHC.Stable GHC.Storable GHC.STRef GHC.TypeLits GHC.TopHandler GHC.Unicode GHC.Weak GHC.Word System.Timeout GHC.Event Control.Applicative Control.Arrow Control.Category Control.Concurrent Control.Concurrent.Chan Control.Concurrent.MVar Control.Concurrent.QSem Control.Concurrent.QSemN Control.Concurrent.SampleVar Control.Exception Control.Exception.Base Control.Monad Control.Monad.Fix Control.Monad.Instances Control.Monad.ST Control.Monad.ST.Safe Control.Monad.ST.Unsafe Control.Monad.ST.Lazy Control.Monad.ST.Lazy.Safe Control.Monad.ST.Lazy.Unsafe Control.Monad.ST.Strict Control.Monad.Zip Data.Bits Data.Bool Data.Char Data.Complex Data.Dynamic Data.Either Data.Eq Data.Data Data.Fixed Data.Foldable Data.Function Data.Functor Data.HashTable Data.IORef Data.Int Data.Ix Data.List Data.Maybe Data.Monoid Data.Ord Data.Ratio Data.STRef Data.STRef.Lazy Data.STRef.Strict Data.String Data.Traversable Data.Tuple Data.Typeable Data.Typeable.Internal Data.Unique Data.Version Data.Word Debug.Trace Foreign Foreign.C Foreign.C.Error Foreign.C.String Foreign.C.Types Foreign.ForeignPtr Foreign.ForeignPtr.Safe Foreign.ForeignPtr.Unsafe Foreign.Marshal Foreign.Marshal.Alloc Foreign.Marshal.Array Foreign.Marshal.Error Foreign.Marshal.Pool Foreign.Marshal.Safe Foreign.Marshal.Utils Foreign.Marshal.Unsafe Foreign.Ptr Foreign.Safe Foreign.StablePtr Foreign.Storable Numeric Prelude System.Console.GetOpt System.CPUTime System.Environment System.Exit System.IO System.IO.Error System.IO.Unsafe System.Info System.Mem System.Mem.StableName System.Mem.Weak System.Posix.Internals System.Posix.Types Text.ParserCombinators.ReadP Text.ParserCombinators.ReadPrec Text.Printf Text.Read Text.Read.Lex Text.Show Text.Show.Functions Unsafe.Coerce Greetings, Joachim -- Joachim nomeata Breitner Debian Developer nome...@debian.org | ICQ# 74513189 | GPG-Keyid: 4743206C JID: nome...@joachim-breitner.de | http://people.debian.org/~nomeata ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe
Re: [Haskell-cafe] Need some advice around lazy IO
On 18 March 2013 21:01, Konstantin Litvinenko to.darkan...@gmail.com wrote: On 03/17/2013 07:08 AM, C K Kashyap wrote: I am working on an automation that periodically fetches bug data from our bug tracking system and creates static HTML reports. Things worked fine when the bugs were in the order of 200 or so. Now I am trying to run it against 3000 bugs and suddenly I see things like - too many open handles, out of memory etc ... Here's the code snippet - http://hpaste.org/84197 It's a small snippet and I've put in the comments stating how I run into out of file handles or simply file not getting read due to lazy IO. I realize that putting ($!) using a trial/error approach is going to be futile. I'd appreciate some pointers into the tools I could use to get some idea of which expressions are building up huge thunks. You problem is in let bug = ($!) fileContents2Bug str ($!) evaluate only WHNF and you need NF. Above just evaluate to first char in a file, not to all content. To fully evaluate 'str' you need something like let bug = Control.DeepSeq.rnf str `seq` fileContents2Bug str Or use $!! from Control.DeepSeq. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] attoparsec and backtracking
On 16 March 2013 12:54, Erik de Castro Lopo mle...@mega-nerd.com wrote: Evan Laforge wrote: The first is that it's hard to get the right error msg out. For instance, I have a parser that tries to parse a number with an optional type suffix. It's an error if the suffix is unrecognized: p_num :: A.Parser Score.TypedVal p_num = do num - p_untyped_num suffix - A.option ((:) $ A.letter_ascii) case Score.code_to_type suffix of Nothing - fail $ p_num expected suffix in [cdsr]: ++ show suffix Just typ - return $ Score.Typed typ num I think the mistake here is to parse something and then decide if its it valid. It should be the parser which decides whether its valid. So rather than: suffix - A.option ((:) $ A.letter_ascii) try: typ - A.choice [ {- list or valid suffix parsers -} ] return $ Score.Typed typ num However, which error msg shows up depends on the order of the (|) alternatives, and in general the global structure of the entire parser, because I think it just backtracks and then picks the last failing backtrack. I'm not sure if what I've offered will help, but its worth a try. Even after carefully rearranging all the parsers it seems impossible to get this particular error to bubble up to the top. Yes, I've found it impossible to force attoparsec to fail a parse. I think that is intended as a feature. I don't know about a feature, but I tried adding polyparse-style commit semantics to attoparsec and couldn't do so without making it rather noticeably slower. The thing is, as soon as I see an unexpected suffix I know I can fail entirely right there, with exactly that error msg, but since there's no way to turn off backtracking I think there's no way to do that. Yes, that's my impression. snip I originally used parsec, but parsing speed is my main bottleneck, so I don't want to give ground there. We you using Parsec as a token parser or as a Char parser. Obviously the second is going to be slow in comparison to the first. I've heard some good things about traditional alex+happy... of course it would mean a complete rewrite but might be interesting. I've user Alex with both Parsec and Happy, where speed was strong secondary goal. Personally I much prefer Parsec; IMO its easier to debug and extend and modify that Happy based parsers. I also know some people prefer Happy. Has anyone compared the performance of attoparsec vs. alex+happy? I haven't, nor have I compared those two with alex+parsec. It would be an interesting experiment. Erik -- -- Erik de Castro Lopo http://www.mega-nerd.com/ ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Open-source projects for beginning Haskell students?
On 12 March 2013 22:46, Tim Docker t...@dockerz.net wrote: On 12/03/13 05:26, Jason Dagit wrote: Myself and several of my friends would find it useful to have a plotting library that we can use from ghci to quickly/easily visualize data. Especially if that data is part of a simulation we are toying with. Therefore, this proposal is for: A gnuplot-, matlab- or plotinum-like plotting API (that uses diagrams as the backend?). The things to emphasize: * Easy to install: No gtk2hs requirement. Preferably just pure haskell code and similar for any dependencies. Must be cross platform. * Frontend: graphs should be easy to construct; customizability is not as important * Backend: options for generating static images are nice, but for the use case we have in mind also being able to render in a window from ghci is very valuable. (this could imply something as purely rendering to JuicyPixels and I could write the rendering code) I maintain the Chart library: http://hackage.haskell.org/package/Chart I'd like to see it used more widely, but gtk/cairo seems to be a problem for many people. Is the cairo dependency the reason you are suggesting that an alternative plotting library be built? Is your problem with cairo the difficulty in setting it up on ms windows/osx? What graphics API would you suggest using to render in a window from ghci? If there were a good cross platform alternative to cairo, I'd happily target this additional 2D drawing API. However, I don't think there currently is one. Neither gloss nor the diagrams library currently have adequate text support. This is probably a completely stupid and bonkers idea... but I wonder whether using Inkscape's ability to be able to export PDF or PS files that can be imported into LaTeX and let LaTeX deal with the text placement/rendering would work... Rather fiddly for just a give me an image library though :) Tim ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Shake, Shelly, FilePath
On 9 March 2013 11:31, Eli Frey eli.lee.f...@gmail.com wrote: I began converting an unwieldy Makefile into a Haskell program via Shake, hoping that I could increase both its readability and modularity. The modularity has increased greatly, and I have found it exhilarating how much more I can express about my dependencies. However, readability has suffered. I quickly found that heavy shell interaction became unwieldy and I came out with code that was much more difficult to scan with my eyes then what I had in my Makefile. I attempted to fix this by using the Shelly library for my shell interactions, and was well pleased until I attempted to compile and discovered Shelly.FilePath is NOT Prelude.FilePath. Now I am left sprinkling coercions all over the place and am again shaking my head at how difficult to scan my code has become. But it _is_ an instance of IsString, so can't you just use {-# LANGUAGE OverloadedStrings #-} and thus get the behaviour you're after (unless you need System.FilePath for something else)? I have been considering writing a shim over Shelly, but the prospect makes me uneasy. Has anyone else walked down this path before, and if so what did you bring away from the experience? I find this situation such a shame, as all my other experiences with both libraries have been quite wonderful. - Eli ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell] Newbie
On 8 March 2013 11:56, Brandon Allbery allber...@gmail.com wrote: On Thu, Mar 7, 2013 at 7:45 PM, Dan Lior sitipo...@gmail.com wrote: 1) Is this the right place for newbies to post questions about Haskell? This is most a list for announcements; beginn...@haskell.org is better for these kinds of questions, and haskell-c...@haskell.org for general discussion. pred :: Int - Int pred 0 = 0 pred n+1 = n n+k patterns were part of Haskell '98, but removed from Haskell 2010. You may be able to use the pragma {-# LANGUAGE NPlusKPatterns #-} to turn them back on. Even then, you need to have pred (n+1) = n. -- brandon s allbery kf8nh sine nomine associates allber...@gmail.com ballb...@sinenomine.net unix, openafs, kerberos, infrastructure, xmonadhttp://sinenomine.net ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell
Re: [Haskell-cafe] ANN: lazy-csv - the fastest and most space-efficient parser for CSV
On 25 February 2013 21:47, Malcolm Wallace malcolm.wall...@me.com wrote: There are lots of Haskell CSV parsers out there. Most have poor error-reporting, and do not scale to large inputs. I am pleased to announce an industrial-strength library that is robust, fast, space-efficient, lazy, and scales to gigantic inputs with no loss of performance. http://code.haskell.org/lazy-csv/ Downloads from Hackage: http://hackage.haskell.org/package/lazy-csv Note that on your website, you list the Hackage URL as having packages rather than package... This library has been in industrial use for several years now, but this is the first public release. No doubt the API is not as general as it could be, but it already serves many purposes very well. I'm happy to receive bug reports and suggestions for improvements. Regards, Malcolm ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] cabal install ghc-mod installs 3 years old version
On 25 February 2013 01:33, Niklas Hambüchen m...@nh2.me wrote: You are right, my ghc-7.4.2 was broken in ghc-pkg list; I fixed the problem by killing my .cabal folder (as so often). Do you know if it is possible to make ghc-pkg list print some actual text when packages are broken instead of writing them in red (which goes away on output redirection)? Just run ghc-pkg check every now and then? Thanks Niklas On 24/02/13 07:34, Ivan Lazar Miljenovic wrote: Which version of GHC (and hence base, etc.)? My guess is that for some reason it thinks that some requirement of the later versions is incompatible with your version of GHC. Maybe explicitly try cabal install 'ghc-mod = 1.11.4' and see why it doesn't like it. -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] cabal install ghc-mod installs 3 years old version
On 24 February 2013 12:38, Niklas Hambüchen m...@nh2.me wrote: Hi, I just did cabal update and cabal install ghc-mod, and for some reason it tries to install version 0.3.0 from 3 years ago: cabal install ghc-mod -v Reading available packages... Choosing modular solver. Resolving dependencies... Ready to install ghc-mod-0.3.0 Downloading ghc-mod-0.3.0... cabal --version cabal-install version 1.16.0.2 using version 1.16.0.3 of the Cabal library Does anyone have an idea why that could be? Which version of GHC (and hence base, etc.)? My guess is that for some reason it thinks that some requirement of the later versions is incompatible with your version of GHC. Maybe explicitly try cabal install 'ghc-mod = 1.11.4' and see why it doesn't like it. Thanks ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] question about: --hyperlink-source
On 21 February 2013 21:18, Doaitse Swierstra doai...@swierstra.net wrote: I ran into the problem that for the packages which I install using cabal install The generated html does not contain links to the sources. This issue was raised before in: http://stackoverflow.com/questions/1587635/haddock-for-cabal-installed-modules I have been looking into the documentation available, but could not find a way to set this e.g. as a default in some .haddock file. Am I overlooking something? I don't think this is currently possible: https://github.com/haskell/cabal/issues/510 Doaitse ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Unused definitions across modules in a package
On 21 February 2013 08:56, Felipe Almeida Lessa felipe.le...@gmail.com wrote: Hey! GHC warns me about unused definitions in a module. However, is it possible to warn me about unused definitions in a package? For example, suppose that module A exports function f and that module B uses A.f (everything on a single package). However, after some time B stops using A.f. Is there a way of receiving a warning saying that A exports f but no other module uses it.? (I know that this warning wouldn't be useful for libraries, since their whole point is to export things.) My (getting-long-in-the-tooth-and-could-do-with-a-rewrite) SourceGraph package does identify these definitions. As for GHC warning about it, I wonder if maybe that's a better role for Cabal as it knows which modules are public vs private (and even libraries can have exported definitions that aren't used from non-exported modules). Cheers! -- Felipe. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] (+) on two lists ?
On 15 February 2013 19:22, Raphael Gaschignard dasur...@gmail.com wrote: Out of curiosity, what is the rationale for allowing programs to infer certain types, but not for the (inferred) type to be declared? That's the type that's needed; the fact that you need an extension for GHC to allow you to use it is irrelevant. On Fri, Feb 15, 2013 at 4:54 PM, David McBride toa...@gmail.com wrote: sum' [] = [] -- returns a list of something the way you intended sum' (x:xs) = x + xum' xs -- you intended it not to return a list but it could if you think about it. The compiler says I think returns a list based on what I see so far, well if you can add these together then the only way you could get a list from that is if you were adding two lists together ie (+ l1 l2) :: [a] - [a] - [a]. That works if we assume that sum' must have accepted [[a]] and returned [a]. But in order for that to be the case [a] must be an instance of Num, otherwise they couldn't be added together like that, so tack on a Num [a] requirement on. But having a typeclass of the form [a] that requires an extension, FlexibleContexts, which you can read about here: http://www.haskell.org/ghc/docs/7.0.2/html/users_guide/other-type-extensions.html#flexible-contexts On Fri, Feb 15, 2013 at 2:33 AM, sheng chen kkchensh...@gmail.com wrote: Hi, I was puzzled by the following little program. sum' [] = [] sum' (x:xs) = x + sum' xs I thought the GHC type checker will report a type error. However, the type checker accepts this program and gives the type Num [a] = [[a]] - [a] When I add type annotation to the program sum' :: Num [a] = [[a]] - [a] sum' [] = [] sum' (x:xs) = x + sum' xs The GHC asks me to add FlexibleContexts language extension. I would appreciate explanation on this issue. Thanks, Sheng ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] When the gauge depends on what it measures
On 14 February 2013 20:56, Gregory Collins g...@gregorycollins.net wrote: While you're benchmarking, rename the library under test and/or its modules. Criterion won't conflict with new-pretty. Alternatively, don't ever actually install your new pretty and just do cabal configure --enable-benchmarks cabal build cabal bench (assuming the benchmark is within the pretty package itself)? G On Thu, Feb 14, 2013 at 10:11 AM, Alexander Bernauer acop...@gmail.com wrote: Hi, I am currently working on benchmarking the pretty library. Pretty itself has no non-trivial dependencies. But criterion and language-c, which I use to perform the benchmarks, directly and/or indirectly depend on pretty. Everything is configured in one Cabal file via library and benchmark sections. Now, whenever I modify pretty and want to rebuild the bench executable, things become messy. Either I rebuild criterion et al. as well, or the bench executable ends up with two different pretty version built in - if this is even possible. Until now I could not find a robust workflow for this scenario. At some point pretty shadows itself and the build fails (c.f. my previous caffee post). What is the right way to handle this scenario? Confused greetings, Alex ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Gregory Collins g...@gregorycollins.net ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
[Haskell] ANNOUNCE: graphviz-2999.16.0.0
I'm pleased to announce that I've finally tracked down all the pesky little bugs that prevented me from releasing version 2999.16.0.0 of my graphviz library, that helps you use the Graphviz suite of tools to visualise graphs. The important changes are: * Add support for Graphviz-2.30.0: - New attributes: + `Area` + `Head_LP` + `LayerListSep` + `LayerSelect` + `Tail_LP` + `XLP` - `BgColor`, `Color` and `FillColor` now take a list of colors with optional weightings. - Layer handling now supports layer sub-ranges. - Added the voronoi-based option to `Overlap`. - Added the `Striped` and `Wedged` styles. * Updates to attributes and their values: - The following attributes have had their values changed to better reflect what they represent: + `FontPath` takes a `Path` value. + `Layout` takes a `GraphvizCommand` (and thus `GraphvizCommand` has been moved to `Data.GraphViz.Attributes.Complete`). - Added `MDS` to `Model` (which had somehow been overlooked). - Various attributes now have defaults added/updated/removed if wrong. - Removed the following deprecated attributes: + `ShapeFile` + `Z` * Now any value that has a defined default can be parsed when the Dot code just has `attribute=` (which `dot -Tcanon` is fond of doing to reset attributes). * `GraphvizCommand` now defines `Sfdp` (which had somehow been overlooked up till now). * The `canonicalise` and related functions have been re-written; whilst there might be some cases where their behaviour does not fully match how `dot -Tcanon` and `tred` behave (due to the interaction of various attributes), the new implementation is much more sane. * Use temporary files rather than pipes when running dot, etc. Makes it more portable, and also avoids issues where dot, etc. use 100% CPU when a graph is passed in via stdin. Original patch by Henning Thielemann. -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell
[Haskell-cafe] ANNOUNCE: graphviz-2999.16.0.0
I'm pleased to announce that I've finally tracked down all the pesky little bugs that prevented me from releasing version 2999.16.0.0 of my graphviz library, that helps you use the Graphviz suite of tools to visualise graphs. The important changes are: * Add support for Graphviz-2.30.0: - New attributes: + `Area` + `Head_LP` + `LayerListSep` + `LayerSelect` + `Tail_LP` + `XLP` - `BgColor`, `Color` and `FillColor` now take a list of colors with optional weightings. - Layer handling now supports layer sub-ranges. - Added the voronoi-based option to `Overlap`. - Added the `Striped` and `Wedged` styles. * Updates to attributes and their values: - The following attributes have had their values changed to better reflect what they represent: + `FontPath` takes a `Path` value. + `Layout` takes a `GraphvizCommand` (and thus `GraphvizCommand` has been moved to `Data.GraphViz.Attributes.Complete`). - Added `MDS` to `Model` (which had somehow been overlooked). - Various attributes now have defaults added/updated/removed if wrong. - Removed the following deprecated attributes: + `ShapeFile` + `Z` * Now any value that has a defined default can be parsed when the Dot code just has `attribute=` (which `dot -Tcanon` is fond of doing to reset attributes). * `GraphvizCommand` now defines `Sfdp` (which had somehow been overlooked up till now). * The `canonicalise` and related functions have been re-written; whilst there might be some cases where their behaviour does not fully match how `dot -Tcanon` and `tred` behave (due to the interaction of various attributes), the new implementation is much more sane. * Use temporary files rather than pipes when running dot, etc. Makes it more portable, and also avoids issues where dot, etc. use 100% CPU when a graph is passed in via stdin. Original patch by Henning Thielemann. -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] ghc-mod and cabal targets
On 8 February 2013 22:25, Francesco Mazzoli f...@mazzo.li wrote: At Fri, 08 Feb 2013 11:39:19 +0100, CJ van den Berg wrote: I downloaded your package and tried it. It does work. So, what I have is bitonic@clay ~/src/kant (git)-[master] % cat .ghci :set -isrc Try also having :set -isrc/dist and possibly :set -isrc/dist/package name (not on a machine with Haskell so I can't test this); I think I've had to do something like that before. And I still get the mentioned error. Did you take any other measures to make things work? I’m using ghc-mod version 1.11.3. Kant.REPL, which it is trying to load, is in the kant package. So it is looking for either the installed kant package, or the source files for the kant package modules. How is that not a package dependency? Telling it where to find the source files will remove the need to find an installed kant package. OK, now I understand what you are doing: instead of making ghc-mod rely on cabal, you simply make it load the files directly. Which is a bit annoying in my case because I have some files that need to be preprocessed (alex/happy), but it would still be better than nothing. I can achieve the same result by simply moving the ‘cabal’ file, or by deleting the target. I guess that the ‘.ghci’ has (or should have) the same effect. Francesco ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Next Meetup
On 4 February 2013 16:27, Christopher Olah christopherolah...@gmail.com wrote: Hey All, I think we were planning on meeting on the second Wednesday of this month (Feb 13) but Hacklab has a members meeting that day. How do people feel about the 14th or 15th? Might help if you specify which location this meetup is intended for; haskell-cafe has a global membership ;-) Chris ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] How to disable document in .cabal file?
On 16 January 2013 13:10, Magicloud Magiclouds magicloud.magiclo...@gmail.com wrote: So the only way is to use param every time I build this certain project? Really hoping I could disable it in project.cabal Well, it's an option for the cabal-install tool, not for the Cabal build system. Note that you don't need to use this parameter every time you build your project, only every time you configure it (so if you don't change the .cabal file much and just tend to build it as you hack on it you don't need the extra params). On Wed, Jan 16, 2013 at 6:45 AM, Albert Y. C. Lai tre...@vex.net wrote: On 13-01-15 12:06 AM, Magicloud Magiclouds wrote: I have enabled document in .cabal/config, so I could get document every time I installed libraries or so. But when I compile my own applications, it also takes time on generating non-exist documents. How to disable it just for this project? If cabal install: add --disable-documentation. See also cabal install --help. If cabal configure and cabal build etc: nothing to do, just omit cabal haddock. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- 竹密岂妨流水过 山高哪阻野云飞 And for G+, please use magiclouds#gmail.com. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] How to disable document in .cabal file?
On 16 January 2013 13:26, Magicloud Magiclouds magicloud.magiclo...@gmail.com wrote: The problem is, I enabled it in ~/.cabal/config file. So by default, when I install, it build the document. Sorry I used build term, by which I meant install How often do you install that this is a problem? If you install more without documentation, disable it in your ~/.cabal/config file, and use --enable-documentation when you actually want it. On Wed, Jan 16, 2013 at 10:16 AM, Ivan Lazar Miljenovic ivan.miljeno...@gmail.com wrote: On 16 January 2013 13:10, Magicloud Magiclouds magicloud.magiclo...@gmail.com wrote: So the only way is to use param every time I build this certain project? Really hoping I could disable it in project.cabal Well, it's an option for the cabal-install tool, not for the Cabal build system. Note that you don't need to use this parameter every time you build your project, only every time you configure it (so if you don't change the .cabal file much and just tend to build it as you hack on it you don't need the extra params). On Wed, Jan 16, 2013 at 6:45 AM, Albert Y. C. Lai tre...@vex.net wrote: On 13-01-15 12:06 AM, Magicloud Magiclouds wrote: I have enabled document in .cabal/config, so I could get document every time I installed libraries or so. But when I compile my own applications, it also takes time on generating non-exist documents. How to disable it just for this project? If cabal install: add --disable-documentation. See also cabal install --help. If cabal configure and cabal build etc: nothing to do, just omit cabal haddock. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- 竹密岂妨流水过 山高哪阻野云飞 And for G+, please use magiclouds#gmail.com. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com -- 竹密岂妨流水过 山高哪阻野云飞 And for G+, please use magiclouds#gmail.com. -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Parallel cabal install ignores order
On 11 January 2013 10:27, Niklas Hambüchen m...@nh2.me wrote: I have jobs: 4 enabled in my cabal config to get parallel installs with cabal-install = 1.16. When I do cabal install --reinstall --force-reinstalls world to reinstall all packages (e.g. to enable profiling or shared), it fails after some point, complaining that the required dependency package is not compiled with the needed flag (for profiling / -dyn). It looks like for reinstalls, parallel cabal-install simply ignores the necessary order. Can somebody confirm this or tell me if this is known? If not, where should it be reported? As an off-the-cuff guess (not having had anything to do with developing cabal-install, etc.), it probably _does_ take dependencies into account... but it sees that the packages are all installed and thus order isn't sufficient. What it seemingly isn't taking into account is the new requirement to have profiling or dynamic builds of existing packages. Thanks Niklas ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell] Cabal update failed
On 2 January 2013 23:07, Chernin, Nadav chern...@corning.com wrote: Hello all, please help me with cabal updating. When i run: cabal update –v3 I get this message: Downloading the latest package list from hackage.haskell.org Sending: GET /packages/archive/00-index.tar.gz HTTP/1.1 Host: hackage.haskell.org User-Agent: cabal-install/0.10.2 Creating new connection to hackage.haskell.org cabal: failed Thanks in advance, Nadav ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell Can you manually run: wget http://hackage.haskell.org/packages/archive/00-index.tar.gz ? -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell
Re: [Haskell-cafe] [Haskell] ANNOUNCE: graphviz-2999.15.0.0
On 1 January 2013 22:41, Henning Thielemann lemm...@henning-thielemann.de wrote: On Tue, 1 Jan 2013, Ivan Lazar Miljenovic wrote: After much prodding and poking by end-users for the past few months, I'm finally able to announce a GHC-7.6.1 compatible release of my Haskell bindings to the Graphviz graph visualisation toolkit: http://hackage.haskell.org/package/graphviz-2999.15.0.0 Did you receive my work-around for the busy-wait problem? Whoops, forgot about that; I'll have a look now. -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
[Haskell] ANNOUNCE: graphviz-2999.15.0.0
After much prodding and poking by end-users for the past few months, I'm finally able to announce a GHC-7.6.1 compatible release of my Haskell bindings to the Graphviz graph visualisation toolkit: http://hackage.haskell.org/package/graphviz-2999.15.0.0 (It took me so long to release a version that allowed bytestring-0.10.* as I was waiting for upstream to get back to me about an inconsistency I found; in the end I decided to just try and cope with how it seems to work.) The list of changes since the last release are: * The repository is now hosted at http://hub.darcs.net/ivanm/graphviz, and using the bug-tracker there. * Updates to various `Attribute` definitions: - The list of available shapes has been expanded to take into account the new synthetic biology shapes. - The `Size` and `FontNames` attributes now have specified data types. - The optional start and end points for `Spline`s were previously the wrong way round; this has now been fixed. - Explicitly only print 2-dimensional `Point` values for `Rect` and `DPoint` (previously only 2-dimensional values where parsed, but it was possible to print a 3-dimensional value). - HTML-like labels previously disallowed empty textual label components when parsing; spotted by Daniel Hummel. * `GraphvizParams` now lets you specify whether a cluster is actually a cluster or a sub-graph. Requested by Gabor Greif. * Fixed an error where printing edges whose attributes contained a `ColorScheme` attribute, that attribute would stay in the state and the old color scheme would override the _parent's_ state. * Previously, some malformed attributes were accepted when being parsed as they silently became parsed as an `UnknownAttribute`. Now, attributes where the attribute name and the equal sign are successfully parsed **but** the value of the attribute is _not_ successfully parse will throw an unrecoverable error. **Note**: this does mean that some Dot graphs that are accepted by Graphviz (as they separate tokenizing from parsing; as such something like `0.1` is successfully accepted as an integer, specifically `0`) are no longer accepted when parsing them in. * Miscellaneous parsing improvements: - Whilst not specified anywhere, Graphviz seems to treat empty quotes as values for attributes expecting a number as their default; as such, this is now taken into account when parsing. - `DPoint` values can now parse an optional `+` prefix. - Whitespaces after commas in HSV colors are now accepted. * Error messages from parsing are improved to help you track down where the parsing error occurred (in that it's easier to find which attribute failed to parse, etc.). -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell
[Haskell-cafe] ANNOUNCE: graphviz-2999.15.0.0
After much prodding and poking by end-users for the past few months, I'm finally able to announce a GHC-7.6.1 compatible release of my Haskell bindings to the Graphviz graph visualisation toolkit: http://hackage.haskell.org/package/graphviz-2999.15.0.0 (It took me so long to release a version that allowed bytestring-0.10.* as I was waiting for upstream to get back to me about an inconsistency I found; in the end I decided to just try and cope with how it seems to work.) The list of changes since the last release are: * The repository is now hosted at http://hub.darcs.net/ivanm/graphviz, and using the bug-tracker there. * Updates to various `Attribute` definitions: - The list of available shapes has been expanded to take into account the new synthetic biology shapes. - The `Size` and `FontNames` attributes now have specified data types. - The optional start and end points for `Spline`s were previously the wrong way round; this has now been fixed. - Explicitly only print 2-dimensional `Point` values for `Rect` and `DPoint` (previously only 2-dimensional values where parsed, but it was possible to print a 3-dimensional value). - HTML-like labels previously disallowed empty textual label components when parsing; spotted by Daniel Hummel. * `GraphvizParams` now lets you specify whether a cluster is actually a cluster or a sub-graph. Requested by Gabor Greif. * Fixed an error where printing edges whose attributes contained a `ColorScheme` attribute, that attribute would stay in the state and the old color scheme would override the _parent's_ state. * Previously, some malformed attributes were accepted when being parsed as they silently became parsed as an `UnknownAttribute`. Now, attributes where the attribute name and the equal sign are successfully parsed **but** the value of the attribute is _not_ successfully parse will throw an unrecoverable error. **Note**: this does mean that some Dot graphs that are accepted by Graphviz (as they separate tokenizing from parsing; as such something like `0.1` is successfully accepted as an integer, specifically `0`) are no longer accepted when parsing them in. * Miscellaneous parsing improvements: - Whilst not specified anywhere, Graphviz seems to treat empty quotes as values for attributes expecting a number as their default; as such, this is now taken into account when parsing. - `DPoint` values can now parse an optional `+` prefix. - Whitespaces after commas in HSV colors are now accepted. * Error messages from parsing are improved to help you track down where the parsing error occurred (in that it's easier to find which attribute failed to parse, etc.). -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Layer on a layer of record syntax in the type synonym?
On 22 December 2012 00:36, Christopher Howard christopher.how...@frigidcode.com wrote: Using a simple type I gave earlier from my monadic type question... code: data Socket3 a b c = Socket3 a b c deriving (Show) Is it possible somehow to layer on record syntax onto a synonym of the type? The idea would be something like this... code: type SpaceShip = Socket3 { engine :: Last Engine , hull :: Last Hull , guns :: [Guns] } ...purely for the convenience. But this doesn't seem to work with type as it assumes you are referring to already made constructors, and evidently newtype only allows use of a single record. I could wrap it in a normal data declaration but that would add an extra layer of complexity I think. No, you can't suddenly add records in just for a type alias. You might be able to create lenses though for setters/getters, though if you just want getters you can just write them yourself. -- frigidcode.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Predicates in data types
On 12 December 2012 21:57, Navid Hallajian navi...@gmail.com wrote: Hello, I'm a beginner in Haskell, so forgive me if this is a basic question, but I'd like to know if it's possible to have a predicate as part of a data type, so that when the data type is created, it can only be done if it satisfies the predicate else a type error is thrown. For instance, a matrix with integer elements could be modelled as [[Int]], given the restrictions that it must have at least one column and one row (so there must be at least one list), and every list must have the same length so that when a matrix is created, the type system wont allow it if the predicates aren't met. Write a custom constructor function that returns a Maybe: newtype Matrix = Matrix [[Int]] makeMatrix :: [[Int]] - Maybe Matrix makeMatrix [] = Nothing -- No columns makeMatrix [[]] = Nothing -- Has a column but no rows ... It is possible with smarter types to encode various predicates into the actual type, but for your purposes they probably aren't required. Thanks, Navid ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] (L)GPL libraries Haskell/GHC (was: Re: ANNOUNCE: tie-knot library)
On 12 December 2012 12:57, Nicolas Trangez nico...@incubaid.com wrote: Note: IANAL On Tue, 2012-12-11 at 17:45 -0800, David Thomas wrote: On Tue, Dec 11, 2012 at 5:35 PM, Brandon Allbery allber...@gmail.comwrote: (Oddly enough, GPL is not the only open source license.) There was no implication to the contrary. It was stated that BSD is a *weaker* license - this is true in the sense that it has fewer requirements (in particular, no copyleft) - and that strong copyleft licenses such as the GPL should be preferred as they do more to bolster the free software community. You can disagree with this claim (there are arguments both ways - delving into them is not my point here) but please try not to bring in straw men. Actually the library is made available under the LGPL-3 license, according to its README, not the GPL (although the latter is implicit, of course). In the Haskell world this does have a different effect compared to when one uses the LGPL for, say, a C library though, since (at least for now) GHC uses/defaults to static linking, which IIRC (though IANAL) turns the LGPL into GPL, so this has a severe impact for application authors. This might be something people aren't aware of when releasing Haskell libraries using the LGPL. I tend to use the LGPL myself for most library-style projects, and do so as well for Haskell code (although I'm aware of the drawbacks), but I'm perfectly fine with people linking the libs statically as long as they comply to the license as if they were using dynamic loading. If anyone knows some standard license which boils down to obligations like LGPL but OK for static linking as well, please let me know. I too would like such a license; however, the closest I've seen is LGPL + linking exception (which I believe is the license Malcolm Wallace uses for the cpphs library, though not the executable). Nicolas ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Hackage dependencies problem.
On 19 November 2012 18:21, Magicloud Magiclouds magicloud.magiclo...@gmail.com wrote: Hi, I am having ghc 7.6.1 working here. But anytime I installed something with cabal-install, I got prompts like: Warning: The following packages are likely to be broken by the reinstalls: haskell98-2.0.0.2 ghc-7.6.1 Cabal-1.16.0 bin-package-db-0.0.0.0 directory-1.2.0.0 hpc-0.6.0.0 Continuing even though the plan contains dangerous reinstalls. And even worse, then I got: command line: cannot satisfy -package Cabal-1.16.0: Cabal-1.16.0-dd0ce1db6fea670a788547ee85411486 is unusable due to missing or recursive dependencies: directory-1.2.0.0-8edf300597b0da609c8eccc9aa6d0cc3 process-1.1.0.2-03ae5757aa509ffbe497f42660cba52c unix-2.6.0.0-4bc27fc415f60036a88211de7cde3e9a (use -v for more information) What should I do? Why user space directory and process would interrupt Cabal in global space? It shouldn't. Can you please give an example of a package that gives you an error like this? Also, what does ghc-pkg check say? The only thing I can think of is that you're trying to upgrade a package like array, containers, etc. -- 竹密岂妨流水过 山高哪阻野云飞 And for G+, please use magiclouds#gmail.com. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] How to determine correct dependency versions for a library?
On 14 November 2012 20:35, Roman Cheplyaka r...@ro-che.info wrote: * Erik Hesselink hessel...@gmail.com [2012-11-12 20:58:17+0100] And I believe the last base changes included a change to 'catch' which would have broken a lot of packages. The Num changes also caused a lot of code changes, and there were probably more I don't remember. Even if so, upper bounds don't prevent these errors. Cabal can't install an older base for you. (I'm aware that GHC once shipped two versions of base, and dependency bounds were actually useful then. But that's not the case nowadays, as we see.) For example, here's what I get when I try to install virthualenv with GHC 7.6.1: % cabal install virthualenv Resolving dependencies... cabal: Could not resolve dependencies: trying: virthualenv-0.2.1 rejecting: base-3.0.3.2, 3.0.3.1 (global constraint requires installed instance) rejecting: base-4.6.0.0/installed-eac... (conflict: virthualenv = base=4.2.0.0 4.6) rejecting: base-4.6.0.0, 4.5.1.0, 4.5.0.0, 4.4.1.0, 4.4.0.0, 4.3.1.0, 4.3.0.0, 4.2.0.2, 4.2.0.1, 4.2.0.0, 4.1.0.0, 4.0.0.0 (global constraint requires installed instance) Doesn't this prevent the error of this package won't build (even if the error message doesn't precisely say that)? Roman ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
[Haskell] ANNOUNCE: pretty-tree
For a project I'm working on, I got sick of writing out trees by hand. Data.Tree has a drawTree function, but whilst it's better than nothing, I prefer a more top-down traditional approach to drawing trees. So I wrote a package to do just that: http://hackage.haskell.org/package/pretty-tree (I didn't think to check whether diagrams had capabilities to do so until after I finished, though in this case I prefer a textual approach anyway.) I'm more than happy to consider adding other forms of drawing trees (though off-hand I can't think of any), or of course you can send me patches since I'm taking advantage of the nice new shiny hub.darcs.net (thanks Darcs team!). I was going to put an example here but it only really comes out nicely if you're using a monospaced font, so have a look at the Haddock docs for the module once Hackage builds it (in hindsight, I should probably have come up with better labels before releasing the package... oh well :) -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell
[Haskell-cafe] ANNOUNCE: pretty-tree
For a project I'm working on, I got sick of writing out trees by hand. Data.Tree has a drawTree function, but whilst it's better than nothing, I prefer a more top-down traditional approach to drawing trees. So I wrote a package to do just that: http://hackage.haskell.org/package/pretty-tree (I didn't think to check whether diagrams had capabilities to do so until after I finished, though in this case I prefer a textual approach anyway.) I'm more than happy to consider adding other forms of drawing trees (though off-hand I can't think of any), or of course you can send me patches since I'm taking advantage of the nice new shiny hub.darcs.net (thanks Darcs team!). I was going to put an example here but it only really comes out nicely if you're using a monospaced font, so have a look at the Haddock docs for the module once Hackage builds it (in hindsight, I should probably have come up with better labels before releasing the package... oh well :) -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] ANNOUNCE: pretty-tree
Which links _aren't_ clickable? If you mean the one to diagrams-contrib, since it isn't imported I can't link to that module directly. One thing I just realised: compared to drawTrees, drawVerticalTree reverses the direction of sub-trees (in that it isn't just equivalent to rotating it clockwise 90 degrees); I'll rectify this when I get to my computer later. On Oct 27, 2012 12:06 AM, Alfredo Di Napoli alfredo.dinap...@gmail.com wrote: The idea is pretty good, although I suggest you make clickable the Haddock's link to modules, because I had to navigate the source in order to find some application as well as nice tree visualizations :) Cheers, A. On 26 October 2012 14:58, Ivan Lazar Miljenovic ivan.miljeno...@gmail.com wrote: For a project I'm working on, I got sick of writing out trees by hand. Data.Tree has a drawTree function, but whilst it's better than nothing, I prefer a more top-down traditional approach to drawing trees. So I wrote a package to do just that: http://hackage.haskell.org/package/pretty-tree (I didn't think to check whether diagrams had capabilities to do so until after I finished, though in this case I prefer a textual approach anyway.) I'm more than happy to consider adding other forms of drawing trees (though off-hand I can't think of any), or of course you can send me patches since I'm taking advantage of the nice new shiny hub.darcs.net (thanks Darcs team!). I was going to put an example here but it only really comes out nicely if you're using a monospaced font, so have a look at the Haddock docs for the module once Hackage builds it (in hindsight, I should probably have come up with better labels before releasing the package... oh well :) -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] License of CloudHaskell code write by Haskell language.
On 11 October 2012 21:47, Chatsiri Ratana insider...@gmail.com wrote: Hello All, License of term of CloudHaskell[1]. It isn't GNU GPL public license. I not sure to include it's to my project. Who know MPI write by haskell pure and not dependent on C/C++ wrapper such as Haskell-mpi[2]? I need to idea for implement OpenMPI standard by Haskell language. Who have an idea for implementing MPI by Haskell? It looks like a 3-clause BSD license, so you can use it within a GPL project if that's what you're asking. [1]https://github.com/jepst/CloudHaskell/blob/master/LICENSE [2]http://hackage.haskell.org/package/haskell-mpi Thank in advance, Chatsiri Rattana. -- : ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Creating Repa arrays from unboxed vectors
On 4 October 2012 20:50, Janek S. fremenz...@poczta.onet.pl wrote: Dear list, I'm trying to create unboxed REPA array from unboxed Vector, but I keep getting this type error: ghci :m + Data.Array.Repa ghci :m + Data.Array.Repa.Repr.Unboxed ghci :m + Data.Vector.Unboxed ghci fromUnboxed Z (Data.Vector.Unboxed.singleton 1) interactive:5:16: Couldn't match expected type `vector-0.9.1:Data.Vector.Unboxed.Base.Vector e0' with actual type `Data.Vector.Unboxed.Vector a0' In the return type of a call of `Data.Vector.Unboxed.singleton' In the second argument of `fromUnboxed', namely `(Data.Vector.Unboxed.singleton 1)' In the expression: fromUnboxed Z (Data.Vector.Unboxed.singleton 1) This makes it look like you've got two versions of vector installed, with Repa built against the version that _isn't_ 0.9.1. I am confused, because REPA documentation lists Vector from Data.Vector.Unboxed package as its second parameter. Why am I getting this error? I have Repa 3.2 an vector 0.9.1. Janek ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] ANN: cabal-install-1.16.0 (and Cabal-1.16.0.1)
On Oct 4, 2012 2:08 AM, Johan Tibell johan.tib...@gmail.com wrote: On the behalf of the many contributors to cabal, I'm proud to present cabal-install-1.16.0. Why the sudden change in versioning scheme (from 0.x to 1.x)? ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] How to take a minimum sub list that only contain certain number of elements of certain type?
On 25 September 2012 16:51, Magicloud Magiclouds magicloud.magiclo...@gmail.com wrote: Hi, For example, I have an array [0..]. Now I want to take a sub list that starts from index 0, and only contain 4 odds, and is minimum result. The answer should be [0, 1, 2, 3, 4, 5, 6, 7]. If you have listTest :: [a] - Bool, then head . dropWhile (not . listTest) . inits ? How to do that? Combining lazy computing, I cannot figure out an efficient algorithm. -- 竹密岂妨流水过 山高哪阻野云飞 And for G+, please use magiclouds#gmail.com. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] How to take a minimum sub list that only contain certain number of elements of certain type?
On 26 September 2012 03:56, Gwern Branwen gwe...@gmail.com wrote: On Tue, Sep 25, 2012 at 1:42 PM, Rishabh Jain rishab...@live.com wrote: f x 0 = [] f (x:xs) y | x `mod` 2 == 0 = x : (f xs y) | otherwise = x : (f xs (y-1)) f [0..] 4 [0,1,2,3,4,5,6,7] Tsk, tsk. So ugly. How's this: let f x = take x . filter odd f 4 [0..] ~ [1, 3, 5, 7] Notice that 0 is excluded, since 0 is *even*, not odd: http://en.wikipedia.org/wiki/Parity_of_zero If this is a serious problem, one can always just prepend zero: 0 : f 4 [1..] ~ [0, 1, 3, 5, 7] Except that your solution is incorrect, as Magicloud wanted the smallest _prefix_ that contained four odd numbers... -- gwern http://www.gwern.net ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Church vs Boehm-Berarducci encoding of Lists
On 18 September 2012 18:27, o...@okmij.org wrote: There has been a recent discussion of ``Church encoding'' of lists and the comparison with Scott encoding. I'd like to point out that what is often called Church encoding is actually Boehm-Berarducci encoding. That is, often seen newtype ChurchList a = CL { cataCL :: forall r. (a - r - r) - r - r } (in http://community.haskell.org/%7Ewren/list-extras/Data/List/Church.hs ) is _not_ Church encoding. First of all, Church encoding is not typed and it is not tight. The following article explains the other difference between the encodings http://okmij.org/ftp/tagless-final/course/Boehm-Berarducci.html Boehm-Berarducci encoding is very insightful and influential. The authors truly deserve credit. P.S. It is actually possible to write zip function using Boehm-Berarducci encoding: http://okmij.org/ftp/ftp/Algorithms.html#zip-folds You have one too many ftp/ in there (in case others get confused about why the link fails). ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language
On 18 September 2012 21:53, José Lopes jose.lo...@ist.utl.pt wrote: Hello Ivan, I agree with your point: if you want a heading that ends with a punctuation sign then you cannot do it in Fmark (for now). That gives me something to think about. However, I will still look for a way that avoids (as much as possible) special syntax. Do you have any suggestion? I also agree with you on the natural conventions. I want to find a good tradeoff between syntax and expressiveness. In other words, I want to avoid as much those odd choices you mentioned. For example, I have been thinking seriously about emphasis and what would be a good way to do it. So far I could only come up with quotes (either or '). What do you think? I think that _emphasis_ is pretty natural, as is *bold* and possibly -strikethrough-. But you _are_ adding in some aspects of markup now. Using quotes is bad because what happens if you're actually quoting someone? ;-) Cheers, José On 18-09-2012 06:05, Ivan Lazar Miljenovic wrote: On 18 September 2012 13:57, José Lopes jose.lo...@ist.utl.pt wrote: Hello Kris, Thank you for your email. At this moment, Fmark is not as powerful as Markdown, also because Fmark just started. Markdown offers things such as Blockquotes, Lists, Code blocks, links, emphasis, images, etc. Fmark does not offer as many features: for now, there are only paragraphs, headings, subsections (endless nesting) and footnotes. In the near future, I want to bolds/italics, ordered and unordered lists, links, and later on as many elements as possible :) The problem with Fmark is also its greatest feature. While other markup languages introduce special syntactic characters to give meaning to the document's elements, I would like to take a different approach: I want to use characters that people already use in document writing to achieve the same result. For example, in Mediawiki a heading is some text surrounded by equal signs. But in Fmark a heading is simply some text that does not end in a punctuation character, such as period or an exclamation mark. I argue that this is a more natural approach. Is it possible to override this? What happens if I want a heading of This is the greatest Heading Ever! ? Natural conventions seem to be to be rather hacky and with lots of corner cases; I think it's better to define a specific syntax for markup (e.g. what is the natural way of emphasising text?) and stick to it (though I agree that Markdown has some odd choices; in particular, the ability to use both _ and * for italics whilst requiring ** for bold). I want to find a natural way of not burdening the user with the task of having to learn some special syntax in order to write a document. Instead I want to find natural ways of writing and use those ways to reconstruct the elements in a document. Of course, what is natural is subjective and that is why I want to find a good tradeoff between expressiveness and simplicity in the syntax. For example, in Fmark a footnote is some text surrounded by square brackets. Maybe you find this natural, maybe you don't. If a handful of people defend a more natural way of writing footnotes I want to implement the way they say. If there is a more natural way of doing this I want to find it. But for now I think square brackets are better than the equal signs or any other strange syntactic character such as exclamation marks and so on... Another thing about Fmark is styles. I want to use fmark personally to write papers, using Latex as backend. While experimenting with previous versions of Fmark I realized that I could not specify the title, the author, the date, and the abstract. which are essential in a paper. I came up with an idea which I think is quite interesting. I wrote another document also using Fmark which only had the words Title, Author, Date, and Abstract. And then I combined these two documents together, such that, Fmark associated title, author, date and abstract, with the corresponding content. I thought the idea was interesting because the content and style documents have both the same structure and are both written in Fmark. Of course, there is still a long way to go, in order to be able to fully customize a document. But styles are a good and simple approach, similar to document classes in Latex: the idea is to write one document (content) and then use multiple (predefined, user defined) styles, such as, article, report, etc, to stylize your document. Another interesting thing I have been thinking about (but not implemented yet) is recursion in document styling. In a way, weaving a style with content can be compared to matching a regular expression. Anyway, these are just some key ideas. I see Fmark as a work in progress and in a way as a research project, trying to find a natural way of writing documents while escaping as much as possible from the syntax
Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language
On Mon, Sep 17, 2012 at 11:09 PM, José Lopes jose.lo...@ist.utl.pt wrote: Hello everyone, I just wanted to share a package I created called Fmark, now available on HackageDB. Feedback both on the project and on the code is greatly appreciated :) Fmark (Friendly Markup) is a very simple markup language without syntax and simple but sophisticated document styling, capable of producing PDF and XML files. The key philosophy behind this markup language is to eliminate the strange syntactic characters seen in most markup languages, but at the same time try to maintain a high level of expressiveness, using only document reconstruction. Check it out http://hackage.haskell.org/package/fmark https://github.com/jabolopes/fmark Best regards, José -- José António Branquinho de Oliveira Lopes 58612 - MEIC-A Instituto Superior Técnico (IST), Universidade Técnica de Lisboa (UTL) jose.lo...@ist.utl.pt ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- José António Branquinho de Oliveira Lopes Instituto Superior Técnico Technical University of Lisbon ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] IO vs MonadIO
On 12 September 2012 18:24, Sergey Mironov ier...@gmail.com wrote: Hi. Just a brief question. System.IO functions are defined in IO monad and have signatures like Foo - IO Bar. Would it be better to have all of them defined as (MonadIO m) = Foo - m Bar? What are the problems that would arise? That would require MonadIO being defined in base, and might make some existing code fail due to lack of type signatures (though I suppose you could specify a default). -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] IO vs MonadIO
On 12 September 2012 19:55, Ivan Lazar Miljenovic ivan.miljeno...@gmail.com wrote: On 12 September 2012 18:24, Sergey Mironov ier...@gmail.com wrote: Hi. Just a brief question. System.IO functions are defined in IO monad and have signatures like Foo - IO Bar. Would it be better to have all of them defined as (MonadIO m) = Foo - m Bar? What are the problems that would arise? That would require MonadIO being defined in base, and might make some existing code fail due to lack of type signatures (though I suppose you could specify a default). Oh, and you'd still need to define them all somewhere to work _for_ IO so you can then have the liftIO variants anyway. -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] [Hackage] Bug report and proposal
On 13 September 2012 04:53, Stayvoid stayv...@gmail.com wrote: Hello, I found a bug: source points to the wrong page. [1] I know that bugs should be reported via Github. But I don't have an account and don't want to create one. There might be others who don't want to use Github. Why rely on external bug tracker? I assume that it has been chosen because of its features, but it doesn't have the most important one (i.e. anonymous posting). What's better: to have more features or to have less bugs? Is it possible to move away from Github? What about a separate mailing list for bugs? Whilst in general I agree with you, people have complained previously about needing to subscribe to librar...@haskell.org for bug reports for boot libraries, or for needing to get a Trac login, etc. If, however, _no_ login is required, then the system is open to spamming :s I'm sorry if this sounds to harsh; I'm not good at writing. I don't want to attack or blame anyone. I'm also sorry if this message is not appropriate, but I haven't found a better place. [1] http://hackage.haskell.org/packages/archive/base/latest/doc/html/Prelude.html#v:seq Cheers ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] ANNOUCE: Haddock 2.10.0 and 2.11.0
On 7 September 2012 23:19, David Waern david.wa...@gmail.com wrote: -- Haddock 2.10.0 and 2.11.0 Two new versions of Haddock have been uploaded to Hackage: version 2.10.0 which comes with GHC 7.4.2 and 2.11.0 which comes with the new GHC 7.6.1! -- Changes in version 2.12.0 So either your changelog has the wrong versions, or else you listed the wrong versions above? ;-) (Or are you just teasing us with the features we'll have with Haddock when GHC 7.8 comes out?) More seriously, it seems there's an error building even 2.12.0 with GHC 7.6; is that correct? http://hackage.haskell.org/packages/archive/haddock/2.12.0/logs/failure/ghc-7.6 * Labeled URLs (e.g http://example.net/ some label) * Improved memory usage (new dependency: deepseq) -- Changes in version 2.11.0 * Show deprecation messages for identifiers * List identifiers declared on the same line (with a common type) separately * Don't crash on unicode strings in doc comments * Fix reporting of modules safe haskell mode * Fix a case where we were generating invalid xhtml * Improved --qual option (no crashes, proper error messages) * A new --qual option aliased which qualifies identifers by the module alias used in the source code * The Haddock API restores GHC's static flags after invocation * Access to unexported identifiers through the Haddock API again -- Links Homepage: http://www.haskell.org/haddock Hackage page: http://hackage.haskell.org/package/haddock-2.12.0 Bugtracker and wiki: http://trac.haskell.org/haddock Mailing list: hadd...@projects.haskell.org Code repository: http://darcs.haskell.org/haddock.git -- Contributors The following people contributed patches to this release: Paolo Capriotti Simon Hengel Ian Lynagh Simon Peyton Jones Iavor S. Diatchki David Terei Henning Thielemann David Waern -- Get Involved We would be very happy to get more contributors. To get involved, start by grabbing the code: http://darcs.haskell.org/haddock.git Then take a look at the bug and feature tracker for things to work on: http://trac.haskell.org/haddock ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell] ANNOUNCE: GHC version 7.6.1
On 7 September 2012 02:05, Ian Lynagh i...@well-typed.com wrote: = The (Interactive) Glasgow Haskell Compiler -- version 7.6.1 = The GHC Team is pleased to announce a new major release of GHC, 7.6.1. Here are some of the highlights of the 7.6 branch since 7.4: * Polymorphic kinds and data promotion are now fully implemented and supported features. * Windows 64bit is now a supported platform. * It is now possible to defer type errors until runtime using the -fdefer-type-errors flag. Is this flag reversible in ghci, so I can :set it to check what's going wrong with some code and then :unset it again? * The RTS now supports changing the number of capabilities at runtime with Control.Concurrent.setNumCapabilities. Full release notes are here: http://www.haskell.org/ghc/docs/7.6.1/html/users_guide/release-7-6-1.html How to get it ~ The easy way is to go to the web page, which should be self-explanatory: http://www.haskell.org/ghc/ We supply binary builds in the native package format for many platforms, and the source distribution is available from the same place. Packages will appear as they are built - if the package for your system isn't available yet, please try again later. Background ~~ Haskell is a standard lazy functional programming language. GHC is a state-of-the-art programming suite for Haskell. Included is an optimising compiler generating good code for a variety of platforms, together with an interactive system for convenient, quick development. The distribution includes space and time profiling facilities, a large collection of libraries, and support for various language extensions, including concurrency, exceptions, and foreign language interfaces (C, whatever). GHC is distributed under a BSD-style open source license. A wide variety of Haskell related resources (tutorials, libraries, specifications, documentation, compilers, interpreters, references, contact information, links to research groups) are available from the Haskell home page (see below). On-line GHC-related resources ~~ Relevant URLs on the World-Wide Web: GHC home page http://www.haskell.org/ghc/ GHC developers' home page http://hackage.haskell.org/trac/ghc/ Haskell home page http://www.haskell.org/ Supported Platforms ~~~ The list of platforms we support, and the people responsible for them, is here: http://hackage.haskell.org/trac/ghc/wiki/Contributors Ports to other platforms are possible with varying degrees of difficulty. The Building Guide describes how to go about porting to a new platform: http://hackage.haskell.org/trac/ghc/wiki/Building Developers ~~ We welcome new contributors. Instructions on accessing our source code repository, and getting started with hacking on GHC, are available from the GHC's developer's site run by Trac: http://hackage.haskell.org/trac/ghc/ Mailing lists ~ We run mailing lists for GHC users and bug reports; to subscribe, use the web interfaces at http://www.haskell.org/mailman/listinfo/glasgow-haskell-users http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs There are several other haskell and ghc-related mailing lists on www.haskell.org; for the full list, see http://www.haskell.org/mailman/listinfo/ Some GHC developers hang out on #haskell on IRC, too: http://www.haskell.org/haskellwiki/IRC_channel Please report bugs using our bug tracking system. Instructions on reporting bugs can be found here: http://www.haskell.org/ghc/reportabug ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell mailing list Haskell@haskell.org http://www.haskell.org/mailman/listinfo/haskell
Re: [Haskell-cafe] How to waitForProcess?
On 5 September 2012 13:45, Magicloud Magiclouds magicloud.magiclo...@gmail.com wrote: Hi, I have code like this and it leaves lots of zombies of flow-export. Then I add waitForProcess Well I do not know where to put it. Before or after 'hGetContents' both make the program hung. You're probably being bitten by hGetContents being lazy. Force the result of hGetContents (e.g. `evaluate . length = hGetContents o ') and then use waitForProcess. exportCSV :: FilePath - IO [String] exportCSV file = do csv_ - withBinaryFile file ReadMode $ \i - do (_, Just o, _, h) - createProcess $ CreateProcess (RawCommand /usr/bin/flow-export [-f2]) Nothing Nothing (UseHandle i) CreatePipe Inherit True False hGetContents o return $ tail $ lines csv_ -- 竹密岂妨流水过 山高哪阻野云飞 And for G+, please use magiclouds#gmail.com. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] hstats median algorithm
On 2 September 2012 05:26, David Feuer david.fe...@gmail.com wrote: The median function in the hstats package uses a naive O(n log n) algorithm. Is there another package providing an O(n) option? If not, what would it take to get the package upgraded? http://hackage.haskell.org/packages/archive/statistics/latest/doc/html/Statistics-Quantile.html#v:medianUnbiased ? hstats appears not to have been updated since 2008 and doesn't build with GHC 7.2 (and presumably 7.4). Maybe try contacting the maintainer? ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Function names in Haskell lib not first-class on web!
On 1 September 2012 01:11, damodar kulkarni kdamodar2...@gmail.com wrote: I knew hoogle to some extent, not an expert user though. and, it seems, the hoogle plugin for firefox works only for haskell.org Because Hoogle indexes the packages on Hackage. Where else can it find it Haskell source code? If I understand correctly, Hoogle (and Hayoo) directly parse the Haskell source code rather than being a search engine in the Google sense. -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Build regressions due to GHC 7.6
On 30 August 2012 15:26, Bryan O'Sullivan b...@serpentine.com wrote: The reasons for these problems fall into three bins: Prelude no longer exports catch, so a lot of import Prelude hiding (catch) had to change. It looks like this might be fixed before the release: http://hackage.haskell.org/trac/ghc/ticket/7167 -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Platform Versioning Policy: upper bounds are not our friends
On 16 August 2012 20:50, Ketil Malde ke...@malde.org wrote: Bryan O'Sullivan b...@serpentine.com writes: I propose that the sense of the recommendation around upper bounds in the PVP be reversed: upper bounds should be specified *only when there is a known problem with a new version* of a depended-upon package. Another advantage to this is that it's not always clear what constitutes an API change. I had to put an upper bound on binary, since 0.5 introduced laziness changes that broke my program. (I later got some help to implement a workaround, but binary-0.4.4 is still substantially faster). Understandably, the authors didn't see this as a breaking API change. Except 0.4 - 0.5 _is_ a major version bump according to the PVP. So, +1. -k -- If I haven't seen further, it is by standing in the footprints of giants ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] For consistency; it would be better if the import statement matched the cabal install statement or :m form.
On 15 August 2012 13:04, KC kc1...@gmail.com wrote: :m +Data.Array.Repa.Algorithms.Randomish cabal install repa.algrothms would be more consistent. Why would that be? They look completely different to me... -- -- Regards, KC -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Platform Versioning Policy: upper bounds are not our friends
On 16 August 2012 08:55, Brandon Allbery allber...@gmail.com wrote: On Wed, Aug 15, 2012 at 6:46 PM, Carter Schonwald carter.schonw...@gmail.com wrote: no one is disputing that there are conditional changes in dependencies depending on library versions. Indeed. But the ghc release that split up base broke cabalised packages with no warning to users until they failed to compile. Upper bounds were put in place to avoid that kind of breakage in the future. There's also the case where people blindly put something like base 10 in the .cabal file, and then it broke on the next GHC release. This happend with ghc-core-0.5: it completely failed to build with base-4 (and because cabal-install kept defaulting packages to use base-3 I think a lot of people missed cases like this and blindly thought it worked). I like having upper bounds on version numbers... right up until people abuse them. -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Does someone have a compiled binary of the LLVM for Windows 7 or must one compile the source?
On 16 August 2012 11:21, KC kc1...@gmail.com wrote: I just want to get started on some matrix operations with REPA. Or is there a library (package?) like REPA without using the LLVM? If you're referring to your recent problems with repa-algorithms, you can try this: cabal unpack repa-algorithms # Not sure of the syntax for changing directories in the cmd.exe terminal cd repa-algorithms-version # Use a text editor to remove the line -fllvm from the .cabal file cabal install -- -- Regards, KC ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] I use cabal install repa but then WinGHCi says module Data.Array.Rep.Algorithms.Ramdomish not found.
On 14/08/2012 7:17 AM, KC kc1...@gmail.com wrote: The install of repa-algorithms fails saying it can't cannot find an llvm. In any case why can't the install syntax be cabal install repa.algorithms then it would be more consistent with the import statement. Because the name of the package is repa-algorithms, not repa.algorithms or Repa.Algorithms. On Sun, Aug 12, 2012 at 4:00 PM, Ivan Lazar Miljenovic ivan.miljeno...@gmail.com wrote: I think you need to install repa-algorithms. On 13 August 2012 04:18, KC kc1...@gmail.com wrote: -- -- Regards, KC ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com -- -- Regards, KC ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] I use cabal install repa but then WinGHCi says module Data.Array.Rep.Algorithms.Ramdomish not found.
I think you need to install repa-algorithms. On 13 August 2012 04:18, KC kc1...@gmail.com wrote: -- -- Regards, KC ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] GHC rendering of non-ASCII characters configurable?
On 31 July 2012 21:01, Richard Cobbe co...@ccs.neu.edu wrote: On Mon, Jul 30, 2012 at 11:45:38PM +1000, Ivan Lazar Miljenovic wrote: On 30 July 2012 04:04, Richard Cobbe co...@ccs.neu.edu wrote: I'm working on an application that involves processing a lot of Unicode data, and I'm finding the built-in Show implementation for Char to be really inconvenient. Specifically, it renders all characters at U+0080 and above with decimal escapes: Prelude '\x80' '\128' This is annoying because all of the Unicode charts give the code points in hex, and indeed the charts are split into different PDFs at numbers that are nice and round in hex but not in decimal. So in order to figure out which character I'm looking at, I have to convert back to hex and then look it up in the charts. Can I ask what you're doing here? Are you printing individual characters or entire chunks of text? Mostly, I'm working with expressions of type String, rather than Text; Any particular reason why? Using Text will probably solve your problem and give you a performance improvement at the same time. -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] The following is supposed to be initializing a 2D array but it doesn't seem to work.
On 1 August 2012 07:52, KC kc1...@gmail.com wrote: newArr :: (Ix i) = i - i - e - Array i e newArr n m x = listArray (n,m) (repeat x) - Prelude Data.Array newArr 0 10 0 array (0,10) [(0,0),(1,0),(2,0),(3,0),(4,0),(5,0),(6,0),(7,0),(8,0),(9,0),(10,0)] Prelude Data.Array newArr (0,0) (5,5) 0 array ((0,0),(5,5)) [((0,0),0),((0,1),0),((0,2),0),((0,3),0),((0,4),0),((0,5),0),((1,0),0),((1,1),0),((1,2),0),((1,3),0),((1,4),0),((1,5),0),((2,0),0),((2,1),0),((2,2),0),((2,3),0),((2,4),0),((2,5),0),((3,0),0),((3,1),0),((3,2),0),((3,3),0),((3,4),0),((3,5),0),((4,0),0),((4,1),0),((4,2),0),((4,3),0),((4,4),0),((4,5),0),((5,0),0),((5,1),0),((5,2),0),((5,3),0),((5,4),0),((5,5),0)] All I am getting is this: array ((1,5),(1,5)) [((1,5),1.0)] Maybe the behaviour of ghc was changed since the article was written. Works for me: $ghci GHCi, version 7.4.2: http://www.haskell.org/ghc/ :? for help Loading package ghc-prim ... linking ... done. Loading package integer-gmp ... linking ... done. Loading package base ... linking ... done. Prelude :m +Data.Array Prelude Data.Array let newArr n m x = listArray (n,m) (repeat x) Prelude Data.Array newArr (0,0) (5,5) 0 array ((0,0),(5,5)) [((0,0),0),((0,1),0),((0,2),0),((0,3),0),((0,4),0),((0,5),0),((1,0),0),((1,1),0),((1,2),0),((1,3),0),((1,4),0),((1,5),0),((2,0),0),((2,1),0),((2,2),0),((2,3),0),((2,4),0),((2,5),0),((3,0),0),((3,1),0),((3,2),0),((3,3),0),((3,4),0),((3,5),0),((4,0),0),((4,1),0),((4,2),0),((4,3),0),((4,4),0),((4,5),0),((5,0),0),((5,1),0),((5,2),0),((5,3),0),((5,4),0),((5,5),0)] Prelude Data.Array Which article are you referring to? -- -- Regards, KC ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] GHC rendering of non-ASCII characters configurable?
On 30 July 2012 04:04, Richard Cobbe co...@ccs.neu.edu wrote: I'm working on an application that involves processing a lot of Unicode data, and I'm finding the built-in Show implementation for Char to be really inconvenient. Specifically, it renders all characters at U+0080 and above with decimal escapes: Prelude '\x80' '\128' This is annoying because all of the Unicode charts give the code points in hex, and indeed the charts are split into different PDFs at numbers that are nice and round in hex but not in decimal. So in order to figure out which character I'm looking at, I have to convert back to hex and then look it up in the charts. Can I ask what you're doing here? Are you printing individual characters or entire chunks of text? putStrLn and similar IO-based functions (at least for me) will un-escape characters if that helps. Otherwise, are you using Text or String? Is there any way to ask GHC to render super-ASCII characters with their hexadecimal escapes, instead? I'm perfectly happy to write my own custom Show instance, but I don't know how to hook that into ghci's REPL (or, for that matter, the routines that HUnit uses to generate the messages on failed tests, etc.). I'm using GHC 7.4.1 on MacOS 10.7.4. Thanks, Richard ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] Which ghc binary does ghc-mod use?
On 24 July 2012 04:06, Peter Simons sim...@cryp.to wrote: Hi, I am a happy user of Emacs with ghc-mod for Haskell programming. There is just one issue I've run into: I have multiple versions of GHC installed on my machine. Now, ghc-mod seems to use the GHC binary that was used to compile ghc-mod itself, but that is not the version I want it to use for syntax checking, etc. In fact, I want to be able to switch ghc-mod between different GHC binaries depending on which project I'm working on, but I have no idea how to do that. Is there maybe some Elisp guru reading this list who can help me out? Can I somehow configure which GHC binary ghc-mod uses? Just to get the potentially obvious out of the way: are you sure it's not a matter of which ghc it finds first in the PATH? It might even be using the internal emacs PATH: (getenv PATH) Take care, Peter ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: [Haskell-cafe] why does a foldr not have a space leak effect?
(Trying again using the real mailing list address rather than google groups) On 24 July 2012 12:37, Qi Qi qiqi...@gmail.com wrote: Hi, I wonder why a foldr does not have a space leak effect? Any hints? Thanks. Why should it? Does it not depend on the function you're folding, the type of data you're folding over, how you use it, etc.? Qi ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe