Home My Page Projects Code Snippets Project Openings SML/NJ
Summary Activity Forums Tracker Lists Tasks Docs Surveys News SCM Files

SCM Repository

[smlnj] Diff of /sml/trunk/src/cm/Doc/manual.tex
ViewVC logotype

Diff of /sml/trunk/src/cm/Doc/manual.tex

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 569, Tue Mar 7 04:01:07 2000 UTC revision 573, Thu Mar 9 15:23:52 2000 UTC
# Line 367  Line 367 
367    
368  Functions that control CM's operation are accessible as members of a  Functions that control CM's operation are accessible as members of a
369  structure named {\tt CM}.  This structure itself is exported from a  structure named {\tt CM}.  This structure itself is exported from a
370  library called {\tt full-cm.cm}.  Other libraries can exploit CM's  library called {\tt smlnj/cm/full.cm} (or, alternatively, {\tt
371  functionality simply by putting a {\tt full-cm.cm} entry into their  smlnj/cm.cm}).  Other libraries can exploit CM's functionality simply
372  own description file.  Section~\ref{sec:dynlink} shows one  by putting a {\tt smlnj/cm/full.cm} entry into their own description file.
373  interesting use of this feature.  Section~\ref{sec:dynlink} shows one interesting use of this feature.
374    
375  Initially, only a ``minimal'' version of structure {\tt CM} (exported  Initially, only a ``minimal'' version of structure {\tt CM} (exported
376  by library {\tt minimal-cm.cm}) is pre-registered at the interactive  by library {\tt smlnj/cm/minimal.cm}) is pre-registered at the interactive
377  prompt.  To make the full version of structure {\tt CM} available, one  prompt.  To make the full version of structure {\tt CM} available, one
378  must explicitly load {\tt full-cm.cm} using {\tt CM.autoload} or {\tt  must explicitly load {\tt smlnj/cm/full.cm} using {\tt CM.autoload} or {\tt
379  CM.make}, both of which are also available in the minimal version.  CM.make}, both of which are also available in the minimal version.
380  (The minimal structure {\tt CM} contains four members: {\tt  (The minimal structure {\tt CM} contains four members: {\tt
381  CM.recomp}, {\tt CM.stabilize}, {\tt CM.make}, and {\tt CM.autoload}.)  CM.recomp}, {\tt CM.stabilize}, {\tt CM.make}, and {\tt CM.autoload}.)
# Line 1068  Line 1068 
1068  Access control is a new feature. At the moment, only the basic  Access control is a new feature. At the moment, only the basic
1069  mechanisms are implemented, but there is no enforcement.  In other  mechanisms are implemented, but there is no enforcement.  In other
1070  words, everybody is assumed to have every possible privilege.  CM  words, everybody is assumed to have every possible privilege.  CM
1071  merely reports which privileges "would have been required".  merely reports which privileges ``would have been required''.
1072    
1073  \section{The pervasive environment}  \section{The pervasive environment}
1074    
# Line 1152  Line 1152 
1152    
1153  CM's tool set is extensible: new tools can be added by writing a few  CM's tool set is extensible: new tools can be added by writing a few
1154  lines of ML code.  The necessary hooks for this are provided by a  lines of ML code.  The necessary hooks for this are provided by a
1155  structure {\tt Tools} which is exported by the {\tt cm-tools.cm}  structure {\tt Tools} which is exported by the {\tt smlnj/cm/tools.cm}
1156  library.  library.
1157    
1158  If the tool is implemented as a ``typical'' shell command, then all  If the tool is implemented as a ``typical'' shell command, then all
# Line 1178  Line 1178 
1178  \end{verbatim}  \end{verbatim}
1179    
1180  This code can either be packaged as a CM library or entered at the  This code can either be packaged as a CM library or entered at the
1181  interactive top level after loading the {\tt cm-tools.cm} library  interactive top level after loading the {\tt smlnj/cm/tools.cm} library
1182  (via {\tt CM.make} or {\tt CM.load\_plugin}).  (via {\tt CM.make} or {\tt CM.load\_plugin}).
1183    
1184  In our example, the shell command name for our tool is {\tt  In our example, the shell command name for our tool is {\tt
# Line 1497  Line 1497 
1497  For the new {\tt f.sml} to be compiled successfully it must be placed  For the new {\tt f.sml} to be compiled successfully it must be placed
1498  into a library {\tt f.cm} that mentions {\tt f-hook.cm} and {\tt  into a library {\tt f.cm} that mentions {\tt f-hook.cm} and {\tt
1499  full-cm.cm}.  As we have seen, {\tt f-hook.cm} exports {\tt F\_Hook.f}  full-cm.cm}.  As we have seen, {\tt f-hook.cm} exports {\tt F\_Hook.f}
1500  and {\tt full-cm.cm} is needed\footnote{The reduced version of  and {\tt smlnj/cm/full.cm} is needed\footnote{The reduced version of
1501  structure {\tt CM} as exported by library {\tt minimal-cm.cm} would  structure {\tt CM} as exported by library {\tt smlnj/cm/minimal.cm} would
1502  have been sufficient, too.}  because it exports {\tt CM.make}:  have been sufficient, too.}  because it exports {\tt CM.make}:
1503  \begin{verbatim}  \begin{verbatim}
1504  Library  Library
# Line 1506  Line 1506 
1506  is  is
1507          f.sml          f.sml
1508          f-hook.cm          f-hook.cm
1509          full-cm.cm          smlnj/cm/full.cm
1510  \end{verbatim}  \end{verbatim}
1511    
1512  \noindent{\bf Beware!}  This solution makes use of {\tt full-cm.cm}  \noindent{\bf Beware!}  This solution makes use of {\tt smlnj/cm/full.cm}
1513  which in turn requires the SML/NJ compiler to be present.  Therefore,  which in turn requires the SML/NJ compiler to be present.  Therefore,
1514  is worthwhile only for really large program modules where the benefits  is worthwhile only for really large program modules where the benefits
1515  of their absence are not outweighed be the need for the compiler.  of their absence are not outweighed be the need for the compiler.

Legend:
Removed from v.569  
changed lines
  Added in v.573

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0