Re: [polyml] Equality Type Parameter in Datatype Declaration

2016-09-17 Thread Matthew Fluet
I think that the reasoning is that the type function induced by a datatype (which maps the type variables to the fresh type name) is ignorant of equality type variables, but the type schemes induced by the constructors do respect equality type variables. Thus, with datatype ('a, ''b) t = A of '

Re: [polyml] Using a finalizer with multiple arguments

2015-09-17 Thread Matthew Fluet
On Thu, Sep 17, 2015 at 6:48 AM, Phil Clayton wrote: > 16/09/15 12:40, David Matthews wrote: >> >> On 15/09/2015 22:18, Phil Clayton wrote: >>> >>> I was wondering how to implement the 'touch' function of >>> MLTON_FINALIZABLE that forces a weak reference to stay alive. The >>> expression >>>

Re: [polyml] Lexical analyser bug?

2015-02-23 Thread Matthew Fluet
Thanks for the nice "teachable moment" to bring to the attention of my Compiler Construction class! I think that a (very) strict reading of the Definition would find in favor of SML/NJ and MLton (and, also, HaMLet), since it requires that lexical analysis take "the longest next item". This is the

Re: [polyml] Performance experiment with Poly/ML

2013-07-26 Thread Matthew Fluet
On Fri, Jul 26, 2013 at 6:07 AM, Jesus Aransay < jesus-maria.aran...@unirioja.es> wrote: > The matrices used for the benchmarks are in a zip file (9MB > compressed, 160MB uncompressed) in the link "Download the benchmarks" > in the previous website. Uncompressing the folder three different > folde

Re: [polyml] Performance experiment with Poly/ML

2013-07-25 Thread Matthew Fluet
On Thu, Jul 25, 2013 at 8:03 AM, David Matthews wrote: > On 25/07/2013 11:29, Jesus Aransay wrote: >> >> Jose Divasón and I wrote a short paper for a Spanish workshop on >> functional programming ("Taller de Programación Funcional 2013", >> http://babel.ls.fi.upm.es/tpf2013/) in which we test a SM

Re: [polyml] suppressing compiler output

2013-04-02 Thread Matthew Fluet
On Tue, Apr 2, 2013 at 8:51 AM, Makarius wrote: > On Tue, 2 Apr 2013, Gergely Buday wrote: > > An ML script could be just tailored rewriting those critical parts in ML >> itself and compiled with mlton if necessary. >> > > I hear that part about Mlton occasionally, and wonder if it is really > s

Re: [polyml] Word31 from SMLNJ

2012-08-21 Thread Matthew Fluet
On Tue, Aug 21, 2012 at 6:08 AM, David Matthews wrote: > On 20/08/2012 23:56, Phil Clayton wrote: >> >> I have to say, if find it surprising that compilers even allow >> Word.word to match the equivalent size Word.word given the >> specification in the Basis Library >>

Re: [polyml] Finalizers not called on termination

2012-08-14 Thread Matthew Fluet
On Mon, Aug 13, 2012 at 5:47 PM, Phil Clayton wrote: > This can be worked around easily, for example by creating a variant of > PolyML.export that adds a final PolyML.fullGC to the exported function (for > both normal and exception paths). However, there is the question of > whether, on terminati

Re: [polyml] Type inference issue with phantom types

2012-07-21 Thread Matthew Fluet
On Sat, Jul 21, 2012 at 10:34 AM, Phil Clayton wrote: > That's immensely useful. I was miles away from value restriction. There > shouldn't be any value restriction issue here - there isn't polymorphism > where you may think there is. As you point out, entering at the top level > gives > > > v

Re: [polyml] IEEE reals

2011-06-17 Thread Matthew Fluet
On Thu, Jun 16, 2011 at 10:53 AM, David Matthews wrote: > I've fixed a bug that Grant Passmore reported where the > IEEEReal.setRoundingMode settings weren't working on X86.  I've written a > small regression test for this particular case but it would be nice to test > Poly/ML's real numbers more

[polyml] Re: [MLton] bug to do with as-binding masking datatype constructor name

2011-04-13 Thread Matthew Fluet
On Wed, Apr 13, 2011 at 9:44 AM, Matthew Fluet wrote: > On Wed, Apr 13, 2011 at 2:49 AM, Andreas Rossberg > wrote: >> On Apr 13, 2011, at 01:49, Michael Norrish wrote: >>> >>> Poly 5.3 rejects >>> >>>  datatype foo = bar of string >>> &g

[polyml] Re: [MLton] bug to do with as-binding masking datatype constructor name

2011-04-13 Thread Matthew Fluet
On Wed, Apr 13, 2011 at 2:49 AM, Andreas Rossberg wrote: > On Apr 13, 2011, at 01:49, Michael Norrish wrote: >> >> Poly 5.3 rejects >> >>  datatype foo = bar of string >> >>  fun f x = let >>   val bar as y = 3 >>  in >>   bar + x >>  end >> >> MLton 20091212~svn accepts it. >> >> Who's right? > >

Re: [polyml] redirecting stdout elsewhere

2010-11-12 Thread Matthew Fluet
I think you want the "setOutstream" function of the IMPERATIVE_IO signature (matched by TextIO), probably in conjunction with the "getOutstream" function. See http://www.standardml.org/Basis/imperative-io.html#SIG:IMPERATIVE_IO.setOutstream:VAL -Matthew On Fri, Nov 12, 2010 at 7:16 PM, Lucas Dix

Re: [polyml] Poly/ML 5.4

2010-08-19 Thread Matthew Fluet
ast line of (the updated) > http://www.polyml.org/FAQ.html#standalone > > David > > Matthew Fluet wrote: >> >> David, >> With that change, I was able to successfully compile MLton with >> Poly/ML; unfortunately, the PolyML.export-ed executable gives a "Bus >&

Re: [polyml] Poly/ML 5.4

2010-08-19 Thread Matthew Fluet
MacOSX (Leopard) does not exhibit the same issue. Perhaps that indicates a 32-bit vs. 64-bit issue? -Matthew On Thu, Aug 19, 2010 at 9:21 AM, Matthew Fluet wrote: > David, > With that change, I was able to successfully compile MLton with > Poly/ML; unfortunately, the PolyML.export-ed e

Re: [polyml] Poly/ML 5.4

2010-08-19 Thread Matthew Fluet
2010 at 6:00 AM, David Matthews wrote: > Matthew, > Thanks for reporting that.  I've installed a fix; well more of a work-around > really and your example now compiles.  I managed to reduce it a few lines > which are now in the regression test suite. > > Regards, > D

Re: [polyml] Poly/ML 5.4

2010-08-17 Thread Matthew Fluet
David, Poly/ML 5.4 (SVN r1192) gives an InternalError exception on the attached program. [...@graywolf mlton-polyml-bug]$ cat mlton-polyml.use | poly Poly/ML 5.4 Experimental ... > Exception- InternalError: getPolyVars: Unable to get type vars raised while > compiling Exception- Fail "Exce

[polyml] Workshop on ML 2010 - Call for Participation

2010-08-10 Thread Matthew Fluet
~~~ * https://regmaster3.com/2010conf/ICFP10/register.php * http://www.icfpconference.org/icfp2010/local.html Program Chair ~ Matthew Fluet Rochester Institute of Technology Program Committee ~ Kathleen Fisher AT&T Labs Research

[polyml] Workshop on ML 2010 - Extended Submission Deadline

2010-06-24 Thread Matthew Fluet
whom this poses a hardship should contact the program chair. Submissions longer than a half a page should include a paragraph synopsis suitable for inclusion in the workshop program. Program Chair ~ Matthew Fluet Rochester Institute of Technology Program Comm

[polyml] Re: [MLton] SML systems disagreeing on Date.localOffset

2010-06-10 Thread Matthew Fluet
MLton's implementation of Date.localOffset is derived from the implementation in the MLKit. I suspect that part of the confusion is the fact that the it isn't clear that the interpretation of the offset field in the record passed to the Date.date function is really a whole other story --- they wou

[polyml] Workshop on ML 2010 - Call for Content

2010-05-23 Thread Matthew Fluet
graph synopsis suitable for inclusion in the workshop program. Program Chair ~ Matthew Fluet Rochester Institute of Technology Program Committee ~ Kathleen Fisher AT&T Labs Research Adam GraniczIntelliFactory Daan Leijen

[polyml] Workshop on ML 2010 - Call for Content

2010-03-03 Thread Matthew Fluet
t two pages, in PDF format, and printable on US Letter or A4 sized paper. Persons for whom this poses a hardship should contact the program chair. Submissions longer than a half a page should include a paragraph synopsis suitable for inclusion in the workshop program. Program Chair ~ Ma

[polyml] bug compiling MLton sources with Poly/ML

2009-10-04 Thread Matthew Fluet
I'm encountering an unexpected (and presumably buggy) type error when compiling the MLton sources with Poly/ML r883. I am able to compile the MLton sources with Poly/ML 5.2.1 (and also MLton and SML/NJ), so I'm fairly certain that the code is type correct. Unfortunately, the set of sharing

[polyml] bugs with datatype replication

2009-10-03 Thread Matthew Fluet
There appears to be a bug with datatype replication when the to-be-replicated type is brought into scope by an open. [fl...@shadow tmp]$ poly Poly/ML 5.3 Release candidate 1 structure S1 = struct open Date datatype t = datatype weekday end; Exception- InternalError: codeVal - Formal raised w

[polyml] structure/signature matching regression in SVN

2009-04-07 Thread Matthew Fluet
From recent SVN commit messages, I see that there has been some reorganization of structure/signature matching; apologies if the reorganization is incomplete (i.e., not ready for testing) and/or the following is a known issue. This program type checks under PolyML 5.2.1 (and SML/NJ 110.68 an

[polyml] Real.fromDecimal and Real.~

2008-06-16 Thread Matthew Fluet
* One bug with the implementation of Real.fromDecimal (which also affects Real.scan and Real.fromString) in PolyML 5.2. The string_buffer[30] in Real_convc in /libpolyml/reals.cpp limits the length of the string seen by strtod to 29 characters. However, the construction of the ML string