🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: alt.lang.ml
Article #22

SML(NJ) on NeXT

#22
From: Todd Simpson
Date: Thu, 12 Nov 1992 23:19
43 lines
1879 bytes
I would like to use SML (NJ) as a serious development tool on the NeXT, meaning
that it should be well integrated with Objective C and Interface Builder.  One
should allow:

    - messages sent from SML to ObjC objects
    - messages sent from ObjC to SML "objects"

The second requirement is paramount; I see application shells constructed with
interface builder, and core functionality (implemented in SML) invoked via the
target/action protocol.

>From SML, the interface might look something like

    signature ObjC =
    sig
    type Class
    type Object
    type Method
    datatype Value = INT of int | OBJ of Object | ...

    val class		: string -> Class
    val inst_method	: Class * string -> Method
    val class_method	: Class * string -> Method
    val invoke_inst	: Object * Method * Value list -> Value
    val invoke_class	: Class * Method * Value list -> Value

    (* Register a procedure for use (as a method) by ObjC *)
    val register	: string * (Value list -> Value) -> unit

    (* Produce an object file containing registered methods *)
    val export		: string -> unit
    end

Of course, this integration depends on being able to generate an object file
consisting of the ml runtime system and a few symbols visible to the linker.

Has anyone done, or thought about, this?

Please mail me your responses, and I will summarize if necessary.

         simpson@cpsc.ucalgary.ca

Thanks
Technical Details
Message-ID: <BxMM5A.H5E@cpsc.ucalgary.ca>
Path: arc1-ca.pugleaf.net!sparky!uunet!destroyer!cs.ubc.ca!alberta!cpsc.ucalgary.ca!simpson

Show Full Headers
Complete Article Headers
Newsgroups: alt.lang.ml,comp.lang.functional,comp.sys.next.prog,comp.sys.next.misc
Path: arc1-ca.pugleaf.net!sparky!uunet!destroyer!cs.ubc.ca!alberta!cpsc.ucalgary.ca!simpson
From: simpson@cpsc.ucalgary.ca (Todd Simpson)
Subject: SML(NJ) on NeXT
Message-ID: <BxMM5A.H5E@cpsc.ucalgary.ca>
Sender: news@cpsc.ucalgary.ca (News Manager)
Organization: University of Calgary Computer Science
Date: Thu, 12 Nov 1992 23:19:57 GMT
Lines: 43