[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Modifiers (revisited)



I would like to request that we adopt a more relaxed view on what
is contained in a module.  The current modifiers for modules (ie.
["C"] EXTERNAL ["lib.o"]) seem to require that all procedures in
a module be external C routines.  It is sometimes convenient,
however to also place Oberon2 routines in the same module.  In
order to support this, I would recommend the following addition
to the set of procedure modifiers:

Procedure modifier
   ["C"]: indicates C-compatible calling parameters
   [EXTERNAL("lib.o")]: means the code is contained in the lib.o object/library
   [NAME("_malloc")]: external procedure name

If a number of modifiers are concatenated what is the syntax?  I would
propose:

   PROCEDURE ["C", EXTERNAL("lib.o"), NAME("_malloc")] MemAlloc (etc.

Michael G.