Changeset 15059 in project for chicken/trunk


Ignore:
Timestamp:
06/25/09 12:57:09 (10 years ago)
Author:
felix winkelmann
Message:

synced changes from wiki into manual

Location:
chicken/trunk
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • chicken/trunk/compiler.scm

    r15057 r15059  
    762762                           e se dest)) )
    763763
    764                        ((define-compiled-syntax)
     764                       ((define-compiled-syntax) ;XXX refactor with the one above
    765765                        (##sys#check-syntax
    766766                         'define-compiled-syntax x
  • chicken/trunk/manual/Callbacks

    r14133 r15059  
    2121do not capture the lexical environment.
    2222
    23 Non-local exits leaving the scope of the invocation of a callback from
    24 Scheme into C will not remove the C call-frame from the stack (and
    25 will result in a memory leak).  '''Note:''' The same applies to
     23Non-local exits leaving the scope of the invocation of a callback from Scheme into C
     24will not remove the C call-frame from the stack (and will result in a memory
     25leak).  '''Note:''' The same applies to
    2626SRFI-18 threading, which is implemented with {{call/cc}};
    2727additionally, if you enter one callback, switch threads and then exit
  • chicken/trunk/manual/Deviations from the standard

    r13683 r15059  
    2929      (set! y tmp2)
    3030      (cons x y) ) )
    31 
    32 [4.3] {{syntax-rules}} macros are not provided but available
    33 separately.
    3431
    3532[6.1] {{equal?}} compares all structured data recursively, while R5RS
  • chicken/trunk/manual/Modules and macros

    r15053 r15059  
    107107        ,@inits)))
    108108
    109 This would not be hygienic, however.  A hygienic {{let}} macro must
    110 rename the identifier {{lambda}} to protect it from being captured by
    111 a local binding.  The renaming effectively creates an fresh alias for
    112 {{lambda}}, one that cannot be captured by any subsequent binding:
     109This would not be hygienic, however.  A
     110hygienic {{let}} macro must rename the identifier {{lambda}} to protect it
     111from being captured by a local binding.  The renaming effectively
     112creates a fresh alias for {{lambda}}, one that cannot be captured by
     113any subsequent binding:
    113114
    114115  (lambda (exp rename compare)
     
    139140in the syntactic environment that will be used to expand the
    140141transformed macro application.  For example, the transformation
    141 procedure for a simplified version of the {{cond}} macro can be
    142 written as
     142procedure for a simplified version of the {{cond}} macro can be written
     143as
    143144
    144145  (lambda (exp rename compare)
  • chicken/trunk/manual/The User's Manual

    r15050 r15059  
    11[[tags:manual]]
    2 
    3 [[image:http://www.call-with-current-continuation.org/chicken4.png]]
    42
    53== The CHICKEN User's Manual
    64
    7 This is the user's manual for the Chicken Scheme compiler, version 4.0.8
     5<nowiki>
     6<img style="float:right; border-left:1px solid #ccc;border-bottom:1px solid #ccc;margin-left:1em;" src="http://www.call-with-current-continuation.org/chicken4.png" alt="Stylized picture of a chicken"/>
     7</nowiki>
     8
     9This is the manual for Chicken Scheme, version 4.0.8.
    810
    911; [[Getting started]] : What is CHICKEN and how do I use it?
  • chicken/trunk/manual/Unit posix

    r15001 r15059  
    3636===== open/rdwr
    3737===== open/read
     38Synonym for {{open/rdonly}}.
     39
    3840===== open/write
     41Synonym for {{open/wronly}}.
     42
    3943===== open/creat
    4044===== open/append
     
    279283
    280284Opens the file specified with the string {{FILENAME}} and open-flags
    281 {{FLAGS}} using the C function {{open()}}. On success a
    282 file-descriptor for the opened file is returned.  {{FLAGS}}
    283 should be a bitmask containing one or more of the {{open/...}}
     285{{FLAGS}} using the C function {{open(2)}}. On success a
     286file-descriptor for the opened file is returned.
     287
     288{{FLAGS}} is a bitmask of {{open/...}}
    284289values '''or'''ed together using {{bitwise-ior}} (or simply added
    285 together).  The optional {{MODE}} should be a bitmask composed of one
     290together).  You must provide exactly one of the access flags {{open/rdonly}}, {{open/wronly}}, or {{open/rdwr}}.  Additionally, you may provide zero or more creation flags ({{open/creat}}, {{open/excl}}, {{open/trunc}}, and {{open/noctty}}) and status flags (the remaining {{open/...}} values).  For example, to open a possibly new output file for appending:
     291
     292 (file-open "/tmp/hen.txt" (+ open/wronly open/append open/creat))
     293
     294The optional {{MODE}} should be a bitmask composed of one
    286295or more permission values like {{perm/irusr}} and is only relevant
    287296when a new file is created. The default mode is
     
    397406{{file-modification-time}}, device id, device type (for special file
    398407inode, blocksize and blocks allocated.  On Windows systems the last 4
    399 values are undefined.  If the optional argument {{LINK}} is given and
    400 not {{#f}}, then the file-statistics vector will be resolved for
    401 symbolic links (otherwise symbolic links are not resolved).
     408values are undefined.
     409
     410By default, symbolic links are followed and
     411the status of the referenced file is returned;
     412however, if the optional argument {{LINK}} is given and
     413not {{#f}}, the status of the link itself is returned.
     414
    402415Note that for very large files, the {{file-size}} value may be an
    403416inexact integer.
     
    11301143current terminal window or {{0}}, {{0}} if the terminal
    11311144size can not be obtained. On Windows, this procedure
    1132 always returns {{0}, {{0}}.
     1145always returns {{0}}, {{0}}.
    11331146
    11341147
  • chicken/trunk/manual/Unit regex

    r13851 r15059  
    99written completely in Scheme.
    1010
    11 This library unit exposes two APIs: the one listed below and the
    12 original irregex API. To use the latter, import from the {{irregex}} module.
     11This library unit exposes two APIs: the standard Chicken API described below, and the
     12original irregex API.  You may use either API or both:
     13
     14 (require-library regex)   ; required for either API, or both
     15 (import regex)            ; import the Chicken regex API
     16 (import irregex)          ; import the original irregex API
    1317
    1418Regular expressions may be either POSIX-style strings (with most PCRE
    1519extensions) or an SCSH-style SRE. There is no {{(rx ...)}} syntax -
    1620just use normal Scheme lists, with quasiquote if you like.
    17 
    18 
    1921
    2022=== grep
  • chicken/trunk/manual/faq

    r13871 r15059  
    11[[toc:]]
    2 [[tags:faq]]
     2[[tags:faq manual]]
    33
    44== FAQ
     
    495495==== Why is my program which uses regular expressions so slow?
    496496
    497 The regular expression engine has recently be replaced by [[alex shinn]]'s excellent
     497The regular expression engine has recently be replaced by [[/users/alex shinn|alex shinn]]'s excellent
    498498{{irregex}} library, which is fully implemented in Scheme. Precompiling regular
    499499expressions to internal form is somewhat slower than with the old PCRE-based
Note: See TracChangeset for help on using the changeset viewer.