Changes To Documentation

Changes to "Documentation" between 2014-06-17 05:07:32 and 2014-06-17 05:14:55

    10     10   Synopsis:
    11     11   
    12     12     1.  `tcc4tcl::cproc <procName> <argList> <returnType> <code>`
    13     13       1. `<procName>` is the name of the Tcl procedure to create
    14     14       1. `<argList>` is a list of arguments and their types for the C function;
    15     15         1. The list is in the format of: type1 name1 type2 name2 ... typeN nameN
    16     16         1. The supported types are:
    17         -         1. Tcl_Interp*
           17  +         1. Tcl_Interp*: Must be first argument, will be the interpreter
    18     18            1. int
    19     19            1. long
    20     20            1. float
    21     21            1. double
    22     22            1. char*
    23         -         1. Tcl_Obj*
           23  +         1. Tcl_Obj*: Passes the Tcl object in unchanged
    24     24            1. void*
    25     25       1. `<returnType>` is the return type for the C function
    26     26         1. The supported types are:
    27     27            1. void: No return value
    28     28            1. ok: Return TCL\_OK or TCL_ERROR
    29     29            1. int
    30         -         1. long 
    31         -    
           30  +         1. long
    32     31            1. float
    33     32            1. double
    34     33            1. char*: TCL_STATIC string (immutable from C)
    35     34            1. string, dstring: TCL_DYNAMIC string (mutable from C)
    36     35            1. vstring: TCL_VOLATILE string (mutable from C)
    37     36            1. default: Tcl_Obj*, a Tcl Object
    38     37       1. `<code>` is the C code that comprises the function
    39     38   
    40     39   Example:
    41     40   
    42         -  1.  `tcc4tcl::cproc add {int a int b} int { return(a+b); }`
           41  +  1.  Create a Tcl procedure called "add" which accepts 2 integers (a, b) and returns a long:
           42  +    1.  `tcc4tcl::cproc add {int a int b} long { return(a+b); }`
    43     43   
    44     44   
    45     45   tcc4tcl::ccode
    46     46   --------------
    47     47   
    48     48   tcc4tcl::cdata
    49     49   --------------