Changeset 13580 in project


Ignore:
Timestamp:
03/08/09 02:04:40 (11 years ago)
Author:
felix winkelmann
Message:

updated manual with some changes from the wiki

Location:
chicken/trunk/manual
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • chicken/trunk/manual/C interface

    r13452 r13580  
    321321 extern int callout(int, int, int);
    322322 <#
    323 
     323 
    324324 (define callout (foreign-safe-lambda int "callout" int int int))
    325 
     325 
    326326 (define-external (callin (scheme-object xyz)) int
    327327   (print "This is 'callin': " xyz)
    328328   123)
    329 
     329 
    330330 (print (callout 1 2 3))
    331331
     
    333333 #include <stdio.h>
    334334 #include "chicken.h"
    335 
     335 
    336336 extern int callout(int, int, int);
    337337 extern int callin(C_word x);
    338 
     338 
    339339 int callout(int x, int y, int z)
    340340 {
    341341   C_word *ptr = C_alloc(C_SIZEOF_LIST(3));
    342342   C_word lst;
    343 
     343 
    344344   printf("This is 'callout': %d, %d, %d\n", x, y, z);
    345345   lst = C_list(&ptr, 3, C_fix(x), C_fix(y), C_fix(z));
  • chicken/trunk/manual/Callbacks

    r7078 r13580  
    2323Non-local exits leaving the scope of the invocation of a callback from Scheme into C
    2424will not remove the C call-frame from the stack (and will result in a memory
    25 leak).
    26 
     25leak).  '''Note:''' The same applies to
     26SRFI-18 threading, which is implemented with {{call/cc}};
     27additionally, if you enter one callback, switch threads and then exit
     28a different callback, your program is likely to crash.
    2729
    2830
  • chicken/trunk/manual/Extensions to the standard

    r10872 r13580  
    161161{{#:append}}.
    162162
     163[6.7] The {{exit}} procedure exits a program right away and does ''not'' invoke pending {{dynamic-wind}} thunks.
     164
    163165Previous: [[Deviations from the standard]]
    164166
  • chicken/trunk/manual/Non-standard macros and special forms

    r12559 r13580  
    5252This is equivalent to {{(require-library ID ...)}} but performs an implicit
    5353{{import}}, if necessary.
     54This implementation of {{require-extension}} is compliant with [[http://srfi.schemers.org/srfi-55/srfi-55.html|SRFI-55]]
     55(see the [[http://srfi.schemers.org/srfi-55/srfi-55.html|SRFI-55]] document for more information).
    5456
    5557==== use
  • chicken/trunk/manual/Non-standard read syntax

    r5945 r13580  
    1515 #;EXPRESSION
    1616
    17 Treats {{EXPRESSION}} as a comment.
    18 
     17Treats {{EXPRESSION}} as a comment.  That is, the comment runs through the whole S-expression, regardless of newlines, which saves you from having to comment out every line, or add a newline in the middle of your parens to make the commenting of the last line work, or other things like that.
    1918=== External Representation
    2019
  • chicken/trunk/manual/Parameters

    r5945 r13580  
    44== Parameters
    55
    6 Certain behavior of the interpreter and compiled programs can be
    7 customized via 'parameters', where a parameter is a procedure of
     6Parameters are Chicken's form of dynamic variables, except that they are
     7procedures rather than actual variables.  A parameter is a procedure of
    88zero or one arguments. To retrieve the value of a parameter call the
    99parameter-procedure with zero arguments. To change the setting of the
     
    3636procedure. The guard procedure should check the value and/or convert it
    3737to an appropriate form.
     38
     39== Built-in parameters
     40
     41Certain behavior of the interpreter and compiled programs can be
     42customized via the following built-in parameters:
    3843
    3944=== case-sensitive
  • chicken/trunk/manual/The User's Manual

    r12920 r13580  
    55This is the user's manual for the Chicken Scheme compiler, version 4.0.0x5
    66
    7 ; [[Overview]] : What is Chicken?
     7; [[Getting started]] : What is CHICKEN and how do I use it?
    88
    99; [[Basic mode of operation]] : Compiling Scheme files.
  • chicken/trunk/manual/Unit eval

    r11013 r13580  
    135135If {{X}} is a macro-form, expand the macro (and repeat expansion
    136136until expression is a non-macro form).  Returns the resulting expression.
    137 
    138 ==== expand*
    139 
    140  [procedure] (expand* X)
    141 
    142 If {{X}} is a macro-form, expand the macro.  Returns the resulting
    143 expression.
    144137
    145138==== undefine-macro!
Note: See TracChangeset for help on using the changeset viewer.