Ignore:
Timestamp:
Mar 13, 2008, 5:00:03 AM (12 years ago)
Author:
gz
Message:

<code> doesn't seem to be valid, so use <varname>.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/doc/src/using.xml

    r8703 r8751  
    186186
    187187    <para>&CCL; provides the
    188       functions <code>CCL:MAP-FILE-TO-IVECTOR</code>
    189       and <code>CCL:MAP-FILE-TO-OCTET-VECTOR</code> to support
     188      functions <varname>CCL:MAP-FILE-TO-IVECTOR</varname>
     189      and <varname>CCL:MAP-FILE-TO-OCTET-VECTOR</varname> to support
    190190      memory-mapping. These functions return vectors whose contents are
    191191      the contents of memory-mapped files. Reading an element of such a
     
    196196      contents of files might be something like this:</para>
    197197
    198     <programlisting>
     198    <para><programlisting>
    199199(let* ((stream (open pathname :direction :input :element-type '(unsigned-byte 8)))
    200200       (vector (make-array (file-size-to-vector-size stream)
    201201                           :element-type '(unsigned-byte 8))))
    202202  (read-sequence vector stream))
    203     </programlisting>
     203    </programlisting></para>
    204204
    205205    <para>Using a memory-mapped files has a result that is the same in
     
    211211      directly, without copying them into memory first.</para>
    212212
    213     <para>The vectors returned by <code>CCL:MAP-FILE-TO-IVECTOR</code>
    214       and <code>CCL:MAP-FILE-TO-OCTET-VECTOR</code> are read-only; any
     213    <para>The vectors returned by <varname>CCL:MAP-FILE-TO-IVECTOR</varname>
     214      and <varname>CCL:MAP-FILE-TO-OCTET-VECTOR</varname> are read-only; any
    215215      attempt to change an element of a vector returned by these
    216216      functions results in a memory-access error. &CCL; does not
    217217      currently support writing data to memory-mapped files.</para>
    218218
    219     <para>Vectors created by <code>CCL:MAP-FILE-TO-IVECTOR</code>
    220       and <code>CCL:MAP-FILE-TO-OCTET-VECTOR</code> are required to
     219    <para>Vectors created by <varname>CCL:MAP-FILE-TO-IVECTOR</varname>
     220      and <varname>CCL:MAP-FILE-TO-OCTET-VECTOR</varname> are required to
    221221      respect &CCL;'s limit on the total size of an array. That means
    222222      that you cannot use these functions to create a vector longer
    223       than <code>ARRAY-TOTAL-SIZE-LIMIT</code>, even if the filesystem
     223      than <varname>ARRAY-TOTAL-SIZE-LIMIT</varname>, even if the filesystem
    224224      supports file sizes that are larger. The value
    225       of <code>ARRAY-TOTAL-SIZE-LIMIT</code> is <code>(EXPT 2 24)</code>
    226       on 32-but platforms; and <code>(EXPT 2 56)</code> on 64-bit
     225      of <varname>ARRAY-TOTAL-SIZE-LIMIT</varname> is <varname>(EXPT 2 24)</varname>
     226      on 32-but platforms; and <varname>(EXPT 2 56)</varname> on 64-bit
    227227      platforms.</para>
    228228
     
    248248            created. Specified as
    249249            a <glossterm linkend="type-specifier">type-specifier</glossterm>
    250             that names a subtype of either <code>SIGNED-BYTE</code>
    251             or <code>UNSIGNED-BYTE</code>.</para>
     250            that names a subtype of either <varname>SIGNED-BYTE</varname>
     251            or <varname>UNSIGNED-BYTE</varname>.</para>
    252252        </listitem>
    253253      </varlistentry>
     
    267267    <para>The returned vector is
    268268      a <glossterm linkend="displaced-array">displaced-array</glossterm>
    269       whose element-type is <code>(UPGRADED-ARRAY-ELEMENT-TYPE
    270         element-type)</code>. The target of the displaced array is a
    271       vector of type <code>(SIMPLE-ARRAY element-type (*))</code> whose
     269      whose element-type is <varname>(UPGRADED-ARRAY-ELEMENT-TYPE
     270        element-type)</varname>. The target of the displaced array is a
     271      vector of type <varname>(SIMPLE-ARRAY element-type (*))</varname> whose
    272272      elements are the contents of the memory-mapped file.</para>
    273273
     
    275275      start a few bytes (4 bytes on 32-bit platforms, 8 bytes on
    276276      64-bit platforms) into the vector. The displaced array returned
    277       by <code>CCL:MAP-FILE-TO-IVECTOR</code> hides this overhead, but
     277      by <varname>CCL:MAP-FILE-TO-IVECTOR</varname> hides this overhead, but
    278278      it's usually more efficient to operate on the underlying simple
    279279      1-dimensional array.  Given a displaced array (like the value
    280       returned by <code>CCL:MAP-FILE-TO-IVECTOR</code>), the function
    281       <code>ARRAY-DISPLACEMENT</code> returns the underlying array and
     280      returned by <varname>CCL:MAP-FILE-TO-IVECTOR</varname>), the function
     281      <varname>ARRAY-DISPLACEMENT</varname> returns the underlying array and
    282282      the displacement index in elements.
    283283    </para>
     
    307307    </para>
    308308
    309     <para>This function is a synonym for <code>(CCL:MAP-FILE-TO-IVECTOR
    310         pathname '(UNSIGNED-BYTE 8))</code> It is provided as a convenience
     309    <para>This function is a synonym for <varname>(CCL:MAP-FILE-TO-IVECTOR
     310        pathname '(UNSIGNED-BYTE 8))</varname> It is provided as a convenience
    311311      for the common case of memory-mapping a file as a vector of
    312312      bytes.</para>
     
    319319
    320320    <para>This function is a synonym
    321       for <code>(CCL:UNMAP-IVECTOR)</code></para>
    322   </sect1>
    323 
    324   <sect1 id="Static Variables">
     321      for <varname>(CCL:UNMAP-IVECTOR)</varname></para>
     322  </sect1>
     323
     324  <sect1 id="Static_Variables">
    325325    <title>Static Variables</title>
    326326
     
    333333
    334334    <para>Attempting to dynamically rebind a static variable (for
    335     instance, by using <code>LET</code>, or using the variable name as
    336     a parameter in a <code>LAMBDA</code> form) signals an
     335    instance, by using <varname>LET</varname>, or using the variable name as
     336    a parameter in a <varname>LAMBDA</varname> form) signals an
    337337    error. Static variables are shared global resources; a dynamic
    338338    binding is private to a single thread.</para>
     
    355355        <parameter>var</parameter>
    356356        <parameter>value</parameter>
    357         <varname>&key;</varname>
     357        &key;
    358358        <parameter>doc-string</parameter>
    359359        [Macro]</command>
     
    388388      assigns the variable the supplied value, and assigns
    389389      the <varname>doc-string</varname> to the
    390       variable's <code>VARIABLE</code> documentation. Marks the
     390      variable's <varname>VARIABLE</varname> documentation. Marks the
    391391      variable static, preventing any attempt to dynamically rebind
    392392      it. Any attempt to dynamically rebind <varname>var</varname>
Note: See TracChangeset for help on using the changeset viewer.