caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Brian Rogoff <bpr@best.com>
To: Jacques Garrigue <garrigue@kurims.kyoto-u.ac.jp>
Cc: bpr@best.com, caml-list@inria.fr
Subject: Re: OCaml's long range graphical direction?
Date: Fri, 9 Feb 2001 10:11:00 -0800 (PST)	[thread overview]
Message-ID: <Pine.BSF.4.21.0102090957480.18552-100000@shell5.ba.best.com> (raw)
In-Reply-To: <20010209102801K.garrigue@kurims.kyoto-u.ac.jp>

On Fri, 9 Feb 2001, Jacques Garrigue wrote:
> From: Brian Rogoff <bpr@best.com>
> > After all of the admonitions against the use of Obj.magic it's a bit
> > disconcerting to count 41 Obj.magic usages in lablgtk. I recall
> > hearing that that will change. What's the plan?
> 
> Do not forget that any "external" declaration also amounts to an
> Obj.magic, and there are 955 of them in lablgtk.

OK, you're right, I deserved that :-)

> Seriously, most Obj.magic in lablgtk amount to a cast of an external
> after checking its validity, and I see no way to avoid that.

Sure, but it seems to me that even if such things are implemented 
with Obj.magic under the hood we ought to come up with new names and 
eventually move "approved and safe usages" to the Sys module. I am 
probably under the influence of Modula-3 and Ada here...

> What should disappear after ocaml 3.01 is release is the use of
>      external coerce ... = "%identity"
> which is an equivalent of Obj.magic used to go around some limitations
> of the type system. There are 24 of them, but they will not be needed
> anymore thanks to variance annotations in types.

Cool, but you also write in another message 

> The last problem is how to stay type safe when you load a text file.
> Basically this means that you will be more verbose, and that will
> compare badly with guile-gtk or python-gtk based applications.

I think for this problem we need some dynamic typing in the language. It 
seems the Clean and Mercury languages have or will adopt such a solution; 
I don't know about Haskell. This is the same issue as with safe
marshalling right, so we are told that there is some help on the way.  

> So, there might be something to do, but I'm not so much convinced it
> will help with a language like ocaml.

Then ocaml will have to become like something else. It won't be the
first time. 

-- Brian




  reply	other threads:[~2001-02-10 21:17 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-02-05 17:48 Daniel Ortmann
2001-02-06  9:28 ` Xavier Leroy
2001-02-06 18:19   ` Sven LUTHER
2001-02-07 21:30     ` Pierre Weis
2001-02-08  7:32       ` Sven
2001-02-08  1:59     ` Jacques Garrigue
2001-02-08  7:55       ` Sven
2001-02-09  8:47         ` Claudio Sacerdoti Coen
2001-02-09 10:00           ` Sven LUTHER
2001-02-08 20:35       ` Brian Rogoff
2001-02-09  1:28         ` Jacques Garrigue
2001-02-09 18:11           ` Brian Rogoff [this message]
2001-02-10 13:01             ` Jacques Garrigue
2001-02-09 20:01           ` Marcin 'Qrczak' Kowalczyk
2001-02-12 14:52             ` Nicolas barnier
2001-02-12 23:47               ` Jacques Garrigue
2001-02-15 12:21                 ` [Caml-list] " Sven LUTHER
2001-02-08 10:28     ` Alan Schmitt
2001-02-09  1:24       ` bcpierce
2001-02-06 20:30   ` Dale Arntson
2001-02-07  0:39   ` John Max Skaller
2001-02-08 20:01   ` Francois Rouaix
2001-02-09  9:41     ` Sven LUTHER
2001-02-09  9:49     ` Jacques Garrigue
2001-02-09 19:58       ` Jerome Vouillon
2001-02-10 12:36         ` Jacques Garrigue
2001-02-10 21:25         ` Pierre Weis
2001-02-09 17:50     ` John Max Skaller
2001-02-06 19:33 Maxence
2001-02-09 23:31 Arturo Borquez

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Pine.BSF.4.21.0102090957480.18552-100000@shell5.ba.best.com \
    --to=bpr@best.com \
    --cc=caml-list@inria.fr \
    --cc=garrigue@kurims.kyoto-u.ac.jp \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).