After far too long, and far too many obstacles to be overcome, Dave MacQueen, Lars Bergstrom, and I have finally prepared an open-source site for the entire family of languages derived from Standard ML. The defining characteristic of Standard ML has always been that it has a mathematically precise definition, so that it is always clear what is a valid program and how it should behave. And indeed we have seven different working compilers, all of which are compatible with each other, with the exception of some corner cases arising from known mistakes in the definition. Moreover, there are several active projects developing new variations on the language, and it would be good to maintain the principle that such extensions be precisely defined.
To this end the sources of the 1990 and 1997 versions of the definition are on the web site, with the permission of MIT Press, as is the type-theoretic definition formulated by Chris Stone and me, which was subsequently used as the basis for a complete machine-checked proof of type safety for the entire language done by Karl Crary, Daniel K. Lee. It is be hoped that the errors in the definition (many are known, we provide links to the extensive lists provided by Kahrs and Rossberg in separate investigations) may now be corrected by a community process. Anyone is free to propose an alteration to be merged into the main branch, which is called “SML, The Living Language” and also known as “Successor ML”. One may think of this as the third edition of the definition, but one that is in continual revision by the community. Computer languages, like natural languages and like mathematics, belong to us all collectively, and we all contribute to their evolution.
Everyone is encouraged to create forks for experimental designs or new languages that enrich, extend, or significantly alter the semantics of the language. The main branch will be for generally accepted corrections, modifications, and extensions, but it is to be expected that completely separate lines of development will also emerge.
The web site, sml-family.org is up and running, and will be announced in various likely places very soon.
Update: We have heard that some people get a “parked page” error from GoDaddy when accessing sml-family.org. It appears to be a DNS propagation problem.
Update: The DNS problems have been resolved, and I believe that the web site is stably available now as linked above.
Filed under: Research Tagged: functional programming, sml
hi i made haskell in snake! i mean...
at the moment its like 170 lines and i'd love to see if anyone can make it shorter, more mathematically sound and or prettier. maybe i need a cabal file? i honestly don't know what i'm doing. someone on #haskell said something about golf.
anyway, this is the first thing i've written in haskell so there is likely lots to fix so here is the repo : )submitted by becky-conning
[link] [42 comments]
Summary: I've just released ghcid, which interactively shows the errors in your project on each save.
I'm please to announce ghcid, which is either "GHCi as a daemon" or "GHC + a bit of an IDE". I've been using it for my development for the last few days, and already find it quite valuable. Unlike other Haskell development tools, ghcid is intended to be incredibly simple. In particular, it doesn't integrate with any editors, doesn't depend on GHC the library and doesn't start web servers. It's under 200 lines of fairly dull Haskell, which talks over pipes to your existing ghci.
Run cabal update && cabal install ghcid to install it as normal. Then run ghcid --height=10 "--command=ghci Main.hs". The height is the number of lines you are going to resize your console window to (defaults to 8), and the command is how you start this project in ghci. Personally, I always create a .ghci file at the root of all my projects, which usually reads something like::set -fwarn-unused-binds -fwarn-unused-imports
With that you can pass --command=ghci (or nothing, since that is the default).
After that, resize your console and make it so you can see it while working in your editor. On Windows the ghcid console will automatically sit on top of all other windows. On Linux, you probably want to use your window manager to make it topmost or use a tiling window manager.
What you get
On every save you'll see a list of the errors and warnings in your project. It uses a single ghci under the hood, so even relatively large projects should update their status pretty quickly. As an example:Main.hs:23:10:
Not in scope: `verbosit'
Perhaps you meant `verbosity' (imported from System.Console.CmdArgs)
Util.hs:18:1: Warning: Defined but not used: `foo'
Or, if everything is good, you see:All good
This project is only a few days old, so please report any bugs you find.
What you want
I regularly use an IDE to develop in a Haskell-like language. I find that with the IDE I'm about 25% more productive than without it. While an IDE can provide lots of neat features (go to definition, search, type tooltips) I think most of the productivity gains come from:
- Syntax coloring.
- A list of errors and warnings...
- ...which is updated as you type...
- ...and are highlighted in the text (red squiggles).
Every text editor already provides syntax coloring. With ghcid you get the list of errors and warnings. To get the final two features you need to integrate with an editor. I'm hoping that ghcid can do some of the heavy lifting by taking a directory of files to treat as overrides, and producing a list of warnings/errors to a file. The rest is editor specific, and I hope to attempt integration with Sublime Text at some point (although would love some help).
I remember when I first went to University, coming across people who were both clearly extremely expert in their fields, from whom I wanted to learn, but were also religious, and how this utterly baffled me. At that point I would cheerfully describe myself as an avid atheist. My ignorance and naivety was somewhat extensive.
Over a decade later I like to think I have a more nuanced view. The most recent war in Gaza led, obviously, to vast amounts of suffering but some excellent articles on the subject (this one by Hadley Freeman in particular) helped me see perspectives more clearly and articulated how crucial it is to be precise with criticism: are you criticising a religion, a people, a government, a policy or something else? Nothing is ever black-and-white and it seems increasingly important to anticipate the consequences of an ill-thought-through comment or reaction. A good example of that is George Galloway's comments this week in the debate about this country once again getting involved in Iraq. On the face of it, and certainly without being remotely well-enough informed to evaluate the accuracy of his claims, if his claims on the size and makeup of ISIS/ISIL are true then there seems little likelihood that the bombing campaigns being discussed will be effective, and quite likely counter-productive. But all of that got lost due his description of Iraqis as quiescent. The way in which that description was seized upon by other MPs and the resultant media storm resulted in the over-shadowing not just of the rest of his contribution to the debate, but also of other important aspects of the debate, such as the resignation of Rushanara Ali (Labour's Shadow Minister for Education), citing once again the lack of a credible long-term plan for the region and our involvement.
Addressing the broader and somewhat more abstract issue is this enlightening article by Karen Armstrong. Again, I'm not claiming to be expert in the area, merely I found the article very educative. It had barely occurred to me that the western world's separation of the secular from the sacred was firstly such a recent occurrence, and secondly that it arose from a specific set of circumstances. There is no implicit reason why separation of state from church is an inevitable or even likely happenstance (to me, this reminds me of the question "if humans evolved from monkeys, then why can't we find monkeys still evolving into humans today?", to which the answer is "the circumstances are not right for that to occur"). The fact that the English word "religion" can't really be translated accurately into other languages (especially not languages that predate English such as Greek or Latin; as historically faith is all encompassing of life, not merely a private affair as we treat it today in the west) starts to show quite how odd the separation of secular from sacred in the modern west really is.
More interesting still is the observation that in the west, belonging to a Nation has in some ways subsumed the role of belonging to a Religion, only apparently with more positive overtones: we consider it almost reprehensible to die for your religion, but honourable to die for your nation. It would seem the concept of even belonging to a nation and having any sense of greater community outside your immediate surroundings only came about with the increased ability of governments to engage with (or intrude upon) their citizens. Before that point, presumably with church attendance widespread and frequent, one's interaction with "the wider world" was through the representative of the church. This would seem to explain a lot about why governments of the past sought the blessing of their nation's church for particular courses of action: maybe the church was seen as the bridge between the government (or monarchy) and the people. The whole article is worth a read.
Just installed the Haskell, Emacs and Haskell-mode. And I tried using C-c C-l to load my .hs file into GHCi but when I do I get this message:
"haskell-mode-enable-process-minor-mode: You tried to do an interaction command, but an interaction mode has not been enabled yet."
Any help??submitted by willrobertshaw
[link] [11 comments]
Hi, I had a ghc-7.8.2 system working. I installed a new version of bytestring, which broken the package system, as "ghc-7.8.2" is shown in braces under ghc-pkg, and I cannot compile anything now. I tried to do "ghc-pkg unregister", but that did not help (it did remove bytestring from the ghc-pkg list, but did not recover ghc-7.8.2, which still shows in braces)
The problem is that I installed the 7.8.2 binary long ago in a local directory from source distribution, using another version that I installed in local directory too, but now I have deleted that other version, so I have no version from which to make a source build again. I tried to download a binary version, but they all fail to install because of different dependencies such as LIBC >=2.7 (I only have 2.5), libffi.so.5, or libedit.so.0. I even tried to build a libedit.so.0, but the downloaded old binary refuses to use it.
I do not have sudo on this machine, so I am limited to what I can install into my local directory.
So is there any way I can recover my 7.8.2 installation? Thanks!submitted by diyu60607
[link] [21 comments]
I came up with the need of using a function that retrieved both minimal and maximal value in a list. I haven’t found that function yet, so I wrote a little implementation:minmax :: (Ord a) => [a] -> (a,a) minmax  = error "empty list: minmax" minmax (x:xs) = foldl (\(mn,mx) a -> (min mn a,max mx a)) (x,x) xs
I guess that can also be written as minmax :: (Ord a,Foldable f).
What do you think? Should such a function be in Data.Ord, Data.List or whatever?submitted by _skp
[link] [18 comments]
I am in the east coast ny area around 9pm Eastern Time. Is hackage down for anyone else?submitted by tempforfather
[link] [2 comments]
The hackage server ran out of disk space temporarily, and when I restarted it, there seemed to be some sort of error with the transaction log. I'm investigating.
I'm currently restoring backups and stuff. This will at worst move back time to to early September 25th, so if you uploaded something, please spread the word.submitted by aseipp
[link] [41 comments]