<?xml version="1.0" encoding="ISO-8859-1"?>

<!DOCTYPE message PUBLIC
  "-//MLarc//DTD MLarc output files//EN"
  "../../mlarc.dtd"[
  <!ATTLIST message
    listname CDATA #REQUIRED
    title CDATA #REQUIRED
  >
]>

  <?xml-stylesheet href="../../mlarc.xsl" type="text/xsl"?>


<message 
  url="2009/10/b12df86f3d2ae39913e2e3a9d6a2afd5"
  from="Jacques Garrigue &lt;garrigue@m...&gt;"
  author="Jacques Garrigue"
  date="2009-10-06T16:31:44"
  subject="Re: [Caml-list] Constructors are not functions"
  prev="2009/10/eef410c2123f8a267621dfdc8c2c22da"
  next="2009/10/9b4d5d1a9bf77b85b658129d148e5d03"
  prev-in-thread="2009/10/ccb202ae118dbc3a11bb5a89174e5551"
  next-in-thread="2009/10/f264a933b70853017a592acf45adc39f"
  prev-thread="2009/10/c0015c890b908f272c4dc603b1de268a"
  next-thread="2009/10/f4c2db533557676eb31a47d6e4761518"
  root="../../"
  period="month"
  listname="caml-list"
  title="Archives of the Caml mailing list">

<thread subject="Constructors are not functions">
<msg 
  url="2009/10/c52bdaf88a932ffd02a17cf12e7a6843"
  from="Chantal KELLER &lt;chantal.keller@w...&gt;"
  author="Chantal KELLER"
  date="2009-10-06T12:01:35"
  subject="Constructors are not functions">
<msg 
  url="2009/10/198f097943e995b4154915c479f6241d"
  from="Philippe Wang &lt;philippe.wang.lists@g...&gt;"
  author="Philippe Wang"
  date="2009-10-06T12:19:59"
  subject="Re: [Caml-list] Constructors are not functions">
<msg 
  url="2009/10/3d94477a1248c4ea3e9b3796fbd96b30"
  from="Jon Harrop &lt;jon@f...&gt;"
  author="Jon Harrop"
  date="2009-10-06T12:37:38"
  subject="Re: [Caml-list] Constructors are not functions">
<msg 
  url="2009/10/8f4a51ef46e423a76ca1a9b355516591"
  from="Richard Jones &lt;rich@a...&gt;"
  author="Richard Jones"
  date="2009-10-06T13:39:01"
  subject="Re: [Caml-list] Constructors are not functions">
</msg>
<msg 
  url="2009/10/e8e36f42040a988ae01a1722a9058a0c"
  from="blue storm &lt;bluestorm.dylc@g...&gt;"
  author="blue storm"
  date="2009-10-10T11:49:25"
  subject="Re: [Caml-list] Constructors are not functions">
</msg>
</msg>
</msg>
<msg 
  url="2009/10/0943a75983cb128775e51daec525fc91"
  from="David Allsopp &lt;dra-news@m...&gt;"
  author="David Allsopp"
  date="2009-10-06T12:45:10"
  subject="RE: [Caml-list] Constructors are not functions">
<msg 
  url="2009/10/9786fb19966b2a45500aaecdb3f831a9"
  from="David Allsopp &lt;dra-news@m...&gt;"
  author="David Allsopp"
  date="2009-10-06T12:46:57"
  subject="RE: [Caml-list] Constructors are not functions">
</msg>
<msg 
  url="2009/10/313b39775708cfcfea942296fb5480ba"
  from="Jim Farrand &lt;jim.farrand@g...&gt;"
  author="Jim Farrand"
  date="2009-10-06T13:14:37"
  subject="Re: [Caml-list] Constructors are not functions">
<msg 
  url="2009/10/3e23a32f43714fe2aaa93dba667b511f"
  from="Michel Mauny &lt;Michel.Mauny@i...&gt;"
  author="Michel Mauny"
  date="2009-10-06T13:50:29"
  subject="Re: [Caml-list] Constructors are not functions">
</msg>
</msg>
<msg 
  url="2009/10/aba0d7c29944654db93a75ba9f263e53"
  from="Jon Harrop &lt;jon@f...&gt;"
  author="Jon Harrop"
  date="2009-10-06T13:15:08"
  subject="Re: [Caml-list] Constructors are not functions">
<msg 
  url="2009/10/fe2ab6fd1ea44b59605e06017966efe8"
  from="David Allsopp &lt;dra-news@m...&gt;"
  author="David Allsopp"
  date="2009-10-06T14:04:08"
  subject="RE: [Caml-list] Constructors are not functions">
<msg 
  url="2009/10/7ba4d13d6fa24170cbd8758b6cd063b3"
  from="Jon Harrop &lt;jon@f...&gt;"
  author="Jon Harrop"
  date="2009-10-06T14:50:46"
  subject="Re: [Caml-list] Constructors are not functions">
</msg>
<msg 
  url="2009/10/ccb202ae118dbc3a11bb5a89174e5551"
  from="Richard Jones &lt;rich@a...&gt;"
  author="Richard Jones"
  date="2009-10-06T15:24:10"
  subject="Re: [Caml-list] Constructors are not functions">
<msg 
  url="2009/10/b12df86f3d2ae39913e2e3a9d6a2afd5"
  from="Jacques Garrigue &lt;garrigue@m...&gt;"
  author="Jacques Garrigue"
  date="2009-10-06T16:31:44"
  subject="Re: [Caml-list] Constructors are not functions">
</msg>
</msg>
<msg 
  url="2009/10/f264a933b70853017a592acf45adc39f"
  from="Goswin von Brederlow &lt;goswin-v-b@w...&gt;"
  author="Goswin von Brederlow"
  date="2009-10-08T12:42:14"
  subject="Re: [Caml-list] Constructors are not functions">
<msg 
  url="2009/10/2f4e4d057ce5bb361d58ef7ac98d95e5"
  from="David Allsopp &lt;dra-news@m...&gt;"
  author="David Allsopp"
  date="2009-10-09T06:29:55"
  subject="RE: [Caml-list] Constructors are not functions">
<msg 
  url="2009/10/e7f2f5d4e0ff800e2527d4e93fdbed96"
  from="Goswin von Brederlow &lt;goswin-v-b@w...&gt;"
  author="Goswin von Brederlow"
  date="2009-10-10T06:25:27"
  subject="Re: [Caml-list] Constructors are not functions">
</msg>
</msg>
</msg>
</msg>
</msg>
</msg>
<msg 
  url="2009/10/94e682caf3469295724fbd74aa679dbb"
  from="Gerd Stolpmann &lt;gerd@g...&gt;"
  author="Gerd Stolpmann"
  date="2009-10-06T13:13:51"
  subject="Re: [Caml-list] Constructors are not functions">
</msg>
<msg 
  url="2009/10/eef410c2123f8a267621dfdc8c2c22da"
  from="Jérémie Dimino &lt;jeremie@d...&gt;"
  author="Jérémie Dimino"
  date="2009-10-06T15:51:01"
  subject="Re: [Caml-list] Constructors are not functions">
<msg 
  url="2009/10/9b4d5d1a9bf77b85b658129d148e5d03"
  from="blue storm &lt;bluestorm.dylc@g...&gt;"
  author="blue storm"
  date="2009-10-06T21:55:17"
  subject="Re: [Caml-list] Constructors are not functions">
</msg>
</msg>
</msg>
</thread>

<contents>
From: Richard Jones &lt;rich@annexia.org&gt;
&gt; It would be so nice to have a macro tool which was aware of types, but
&gt; that tool isn't camlp4.  There are probably theoretical problems with
&gt; this, but having a "give_me_the_type_of (ocaml_subexpression)"
&gt; function would be awesome indeed.

The trouble here is that the type of the subexpression depends on its
context... so that you would need to have already typed the whole
expression to do that. If you are extending the syntax, this is a
rather strong requirement. On the other hand, if you design your
extension so that the program is typable before transforming it, then
it would not be theoretically impossible to have campl4 read the
dumped types and use them for an extra pass. You would still need to
type everything once more after that for safety.

Jacques Garrigue

</contents>

</message>

