From risto.saarelma at ssh.com Mon Mar 23 01:49:07 2009 From: risto.saarelma at ssh.com (Risto Saarelma) Date: Tue Mar 24 00:25:20 2009 Subject: [MLton-user] Type error with the exit status from MLton.Process.reap Message-ID: <20090323094907.GA6198@localdomain> Hi I'm trying to read the exit status of a process run with MLton.Process. I use this code: open MLton.Process val () = let val proc = MLton.Process.create { args = [], env = NONE, path = "/usr/bin/ls", stderr = Param.pipe, stdin = Param.null, stdout = Param.pipe} val exitStatus = reap proc in case exitStatus of Posix.Process.W_EXITSTATUS st => print "Error code.\n" | _ => print "Something else.\n" end Using MLton 20070826, I get the following error: $ mlton proctest.sml Error: proctest.sml 15.9. Case object and rules disagree. object type: [?.PosixProcess.exit_status] rules expect: [Unix.exit_status] in: case exitStatus of (Posix.Process ... "Something else.\n") compilation aborted: parseAndElaborate reported errors MLton.Process.reap is supposed to return a value of type Posix.Process.exit_status, and the actual Posix.Process.exit_status is apparently just an alias for Unix.exit_status. So why am I getting the type error? Risto Saarelma From neal at glew.name Wed Mar 25 06:34:53 2009 From: neal at glew.name (Neal Glew) Date: Wed Mar 25 06:37:19 2009 Subject: [MLton-user] Order of Vector.tabulate Message-ID: <18890.16653.368773.484746@glew1.glew.org> Is it reasonable or not to assume that Vector.tabulate (n, f) will call f 0, f 1, ..., and then f (n-1)? For example, if g reads something from a file and I write Vector.tabulate (n, fn _ => g ()) will I get a vector of somethings from the file in order? If not, what should I use instead? Neal From vesa.a.j.k at gmail.com Wed Mar 25 07:28:40 2009 From: vesa.a.j.k at gmail.com (Vesa Karvonen) Date: Wed Mar 25 07:29:14 2009 Subject: [MLton-user] Order of Vector.tabulate In-Reply-To: <18890.16653.368773.484746@glew1.glew.org> References: <18890.16653.368773.484746@glew1.glew.org> Message-ID: <9e43b9a0903250828p4efe3395h58af2aae653ef0c0@mail.gmail.com> On Wed, Mar 25, 2009 at 4:34 PM, Neal Glew wrote: > Is it reasonable or not to assume that Vector.tabulate (n, f) will > call f 0, f 1, ..., and then f (n-1)? ?For example, if g reads > something from a file and I write Vector.tabulate (n, fn _ => g ()) > will I get a vector of somethings from the file in order? It is and yes. The order is specified in the Basis Library spec. See http://www.standardml.org/Basis/vector.html#SIG:VECTOR.tabulate:VAL and http://www.standardml.org/Basis/list.html#SIG:LIST.tabulate:VAL . -Vesa Karvonen From henry.cejtin at sbcglobal.net Wed Mar 25 08:26:10 2009 From: henry.cejtin at sbcglobal.net (Henry Cejtin) Date: Wed Mar 25 08:26:42 2009 Subject: [MLton-user] Order of Vector.tabulate References: <18890.16653.368773.484746@glew1.glew.org> Message-ID: <986879.33815.qm@web82405.mail.mud.yahoo.com> The official SML Basis Library says that Vector.tabulate (n, f) is equivalent to Vector.fromList (List.tabulate (n, f)) and also says that List.tabulate creates the list from left to right, so it certainly looks to me like the result is completely determined. ----- Original Message ---- From: Neal Glew To: mlton-user@mlton.org Sent: Wednesday, March 25, 2009 9:34:53 AM Subject: [MLton-user] Order of Vector.tabulate Is it reasonable or not to assume that Vector.tabulate (n, f) will call f 0, f 1, ..., and then f (n-1)? For example, if g reads something from a file and I write Vector.tabulate (n, fn _ => g ()) will I get a vector of somethings from the file in order? If not, what should I use instead? Neal _______________________________________________ MLton-user mailing list MLton-user@mlton.org http://mlton.org/mailman/listinfo/mlton-user From urban at math.lmu.de Wed Mar 25 10:31:37 2009 From: urban at math.lmu.de (urban@math.lmu.de) Date: Wed Mar 25 10:31:42 2009 Subject: [MLton-user] WMM'09 call for papers Message-ID: <20090325193137.ll7j3wnascw00ok8@webmail.mathematik.uni-muenchen.de> Call for Papers 4rd Informal ACM SIGPLAN Workshop on Mechanizing Metatheory Edinburgh, Scotland Co-located with ICFP'09. http://www.cis.upenn.edu/~sweirich/wmm/ Important Dates * Submission deadline: 19 June 2009 * Author Notification: 24 July 2009 * Workshop: 4 September 2009 Workshop Description Researchers in programming languages have long felt the need for tools to help formalize and check their work. With advances in language technology demanding deep understanding of ever larger and more complex languages, this need has become urgent. There are a number of automated proof assistants being developed within the theorem proving community that seem ready or nearly ready to be applied in this domain-yet, despite numerous individual efforts in this direction, the use of proof assistants in programming language research is still not commonplace: the available tools are confusingly diverse, difficult to learn, inadequately documented, and lacking in specific library facilities required for work in programming languages. The goal of this workshop is to bring together researchers who have experience using automated proof assistants for programming language metatheory, and those who are interested in using tool support for formalizing their work. One starting point for discussion will be the obstacles that hinder mechanization (whether they be pragmatic or technical), and what users and developers can do to overcome them. Format The workshop will consist of presentations by the participants, selected from submitted abstracts. It will focus on providing a fruitful environment for interaction and presentation of ongoing work. Participants are invited to submit working notes, source files, and abstracts for distribution to the attendees, but as the workshop has no formal proceedings, contributions may still be submitted for publication elsewhere. (See the SIGPLAN republication policy for more details.) Scope The scope of the workshop includes, but is not limited to: * Tool demonstrations: proof assistants, logical frameworks, visualizers, etc. * Libraries for programming language metatheory. * Formalization techniques, especially with respect to binding issues. * Analysis and comparison of solutions to the POPLmark challenge. * Examples of formalized programming language metatheory. * Proposals for new challenge problems that benchmark programming language work. Submission Guidelines Email submissions to urbanc AT in.tum.de. Submissions should be no longer than two pages in PDF and printable on A4 sized paper. Persons for whom this poses a hardship should contact the program chair. Conference Organization Program Committee * Nick Benton, Microsoft Research Cambridge * Olivier Danvy, University of Aarhus * Daniel Licata, Carnegie Mellon University * Francois Pottier, INRIA Paris-Rocquencourt * Christian Urban, TU Munich (chair) Workshop Organizers * Karl Crary, Carnegie Mellon University * Michael Norrish, National ICT Australia * Stephanie Weirich, University of Pennsylvania Previous Workshops * Victoria, 2008 * Freiburg, 2007 * Portland, 2006 ---------------------------------------------------------------- This message was sent using IMP, the Internet Messaging Program. From ville at laurikari.net Thu Mar 26 13:11:31 2009 From: ville at laurikari.net (Ville Laurikari) Date: Fri Mar 27 11:32:00 2009 Subject: [MLton-user] Re: [MLton] MLton: A few questions In-Reply-To: <109192576@web.de> References: <109192576@web.de> Message-ID: <20090326211131.GB19447@laurikari.net> On Wed, Mar 25, 2009 at 05:18:50PM +0100, emil artin wrote: > Hi, > 1) Is there any howto or guide about custom compilation of MLton? > I would like to compile a 64bit version of MLton on AIX and Solaris myself! For any supported platform, you just run "make all-no-docs" to build it, or "make all" if you have the LaTeX toolset needed for building the documentation. You need a working MLton in path, though, to be able to do a normal compile of MLton. You can find binaries at http://mlton.org/Download and http://mlton.org/Experimental I have recent 64-bit builds of MLton for AIX and Solaris (amd64). I'll upload the binaries on the Experimental page so you can give it a whirl. > 2) Is it possible (or sensible) to use a non gcc compiler (e.g. xlc on AIX)? No. In theory, I suppose it would be possible to modify MLton to work with a different compiler, but I don't see the point. > 3) What are the prerequisites? I know about gmp and SML/NJ. > Is SML/NJ absolutely necessary? SML/NJ is not needed, unless you want to bootstrap using SML/NJ. Normally, you would use MLton to build MLton. You do need a set of GNU tools and libraries. I believe these are sufficient: - gcc - gmp - GNU make - bash In addition, the build process uses things like tar, patch, sed, grep, find, "mkdir -p", etc. You may have to get the GNU versions of these as well, but probably not. Also, to build MLton with itself, you need a couple of gigabytes of memory. You may get by with 1.5G or possibly even just one gig, but I'd consider two gigabytes a minimum. > 4) Does MLton generate an executable file from SML code by first compiling it into C > and then using a C compiler to compile it to an executable file? Yes, except on the most popular architectures (x86 and amd64) we have native support and generate assembler (.S) instead of C. On other architectures, where MLton doesn't have a native code generator, MLton generates C code instead of assembler. Compiling the .c and .S files and linking the final executable is done with GCC. -- http://www.iki.fi/vl/ From spoons at cmu.edu Fri Mar 27 06:15:05 2009 From: spoons at cmu.edu (Daniel Spoonhower) Date: Fri Mar 27 11:32:08 2009 Subject: [MLton-user] Re: [MLton] MLton: A few questions In-Reply-To: <109192576@web.de> References: <109192576@web.de> Message-ID: <49CCDF69.3040009@cmu.edu> (I will take a shot, but others should correct me if I get anything wrong.) emil artin wrote: > Hi, > > I have a few questions about MLton which I want to ask > and hope that experienced users on this list can answer my questions. > > 1) Is there any howto or guide about custom compilation of MLton? > I would like to compile a 64bit version of MLton on AIX and Solaris myself! I think it's as simple as "untar and make." That assumes there is a working SML compiler on the platform on which you are building. > 2) Is it possible (or sensible) to use a non gcc compiler (e.g. xlc on AIX)? I believe that any C99-compliant compiler will work. Try the -cc option. > 3) What are the prerequisites? I know about gmp and SML/NJ. > Is SML/NJ absolutely necessary? Some SML compiler is necessary, as well as gmp. You might consider cross-compiling: http://mlton.org/CrossCompiling Or perhaps the existing build for Solaris will be sufficient to bootstrap? > 4) Does MLton generate an executable file from SML code by first compiling it into C > and then using a C compiler to compile it to an executable file? MLton includes several code generators: native code generators for x86 and x86-64 (AKA amd64) and a C code generator that is used on other architectures. The C code generator works as you describe. > Any help is very much appreciated? > > Regards, > E.A. > > PS: Evidently the activities on MLton has been decreased dramatically during the past few months. > It seems that the project leaders don't have much time for further developement of MLton. > What is going on? From ville at laurikari.net Fri Mar 27 11:15:38 2009 From: ville at laurikari.net (Ville Laurikari) Date: Fri Mar 27 11:32:16 2009 Subject: [MLton-user] Re: [MLton] MLton: A few questions Message-ID: <20090327191538.GA610@laurikari.net> I'm resending this to the list. The first attempt didn't seem to go through. ----- Forwarded message from Ville Laurikari ----- Date: Thu, 26 Mar 2009 23:11:31 +0200 From: Ville Laurikari To: emil artin Cc: mlton-user@mlton.org Subject: Re: [MLton] MLton: A few questions User-Agent: Mutt/1.5.17+20080114 (2008-01-14) On Wed, Mar 25, 2009 at 05:18:50PM +0100, emil artin wrote: > Hi, > 1) Is there any howto or guide about custom compilation of MLton? > I would like to compile a 64bit version of MLton on AIX and Solaris myself! For any supported platform, you just run "make all-no-docs" to build it, or "make all" if you have the LaTeX toolset needed for building the documentation. You need a working MLton in path, though, to be able to do a normal compile of MLton. You can find binaries at http://mlton.org/Download and http://mlton.org/Experimental I have recent 64-bit builds of MLton for AIX and Solaris (amd64). I'll upload the binaries on the Experimental page so you can give it a whirl. > 2) Is it possible (or sensible) to use a non gcc compiler (e.g. xlc on AIX)? No. In theory, I suppose it would be possible to modify MLton to work with a different compiler, but I don't see the point. > 3) What are the prerequisites? I know about gmp and SML/NJ. > Is SML/NJ absolutely necessary? SML/NJ is not needed, unless you want to bootstrap using SML/NJ. Normally, you would use MLton to build MLton. You do need a set of GNU tools and libraries. I believe these are sufficient: - gcc - gmp - GNU make - bash In addition, the build process uses things like tar, patch, sed, grep, find, "mkdir -p", etc. You may have to get the GNU versions of these as well, but probably not. Also, to build MLton with itself, you need a couple of gigabytes of memory. You may get by with 1.5G or possibly even just one gig, but I'd consider two gigabytes a minimum. > 4) Does MLton generate an executable file from SML code by first compiling it into C > and then using a C compiler to compile it to an executable file? Yes, except on the most popular architectures (x86 and amd64) we have native support and generate assembler (.S) instead of C. On other architectures, where MLton doesn't have a native code generator, MLton generates C code instead of assembler. Compiling the .c and .S files and linking the final executable is done with GCC. -- http://laurikari.net/ville/ From fluet at tti-c.org Fri Mar 27 13:03:29 2009 From: fluet at tti-c.org (Matthew Fluet) Date: Fri Mar 27 12:01:49 2009 Subject: [MLton-user] mailing list issues Message-ID: Just a note to clarify some issues that regular readers and new subscribers may be wondering about: * The 'mlton@mlton.org' and 'mlton-user@mlton.org' administrative e-mails are routed to my GMail account. For mysterious reasons, since Dec. 2008, GMail has decided that all such admin e-mails are spam, and therefore I haven't been noticing when they arrive. * Both mailing lists are protected by the same whitelist, which explains why first-time posters often have a delay before their message appears on the list. (Similarly, first-time post from a new e-mail address may also have a delay). * There are filters in place on the mailing list that hold "Re: [MLton]" messages sent to mlton-user@mlton.org for administrator approval (and vice versa) to cut down on unnecessary cross-posting. * Any non-whitelisted post is sent to the list administrators. This lets us add new entries to the whitelist and bounce legitimate messages back to the lists. On the other hand, it means that there is a ton of spam coming at the list administrators, which explains why I can't simply include a GMail filter that accepts everything from @mlton.org as not-spam. I think I've caught up with all outstanding administrator requests (at least as far as my 30-days of GMail spam is concerned). I sincerely apologize to the subscription requests from Dec. and Jan. that just now got processed. I will attempt to fine tune some filters to avoid these issues in the future. -Matthew