Changeset 13683 in project


Ignore:
Timestamp:
03/11/09 15:15:21 (11 years ago)
Author:
felix winkelmann
Message:

slight manual fixes; wiki2html improvements

Location:
chicken/trunk
Files:
1 added
1 deleted
44 edited

Legend:

Unmodified
Added
Removed
  • chicken/trunk/manual/Accessing external objects

    r10398 r13683  
    173173return-type should be omitted.
    174174
    175 
     175---
    176176Previous: [[Interface to external functions and variables]]
    177177
  • chicken/trunk/manual/Acknowledgements

    r13452 r13683  
    7373Lisp Pointers. IV(4). December 1991.
    7474
     75---
    7576Previous: [[FAQ]]
    7677
  • chicken/trunk/manual/Basic mode of operation

    r13670 r13683  
    5454dynamically into a running application.
    5555
    56 Previous: [[Overview]]
     56---
     57Previous: [[Getting started]]
    5758
    5859Next: [[Using the compiler]]
  • chicken/trunk/manual/Bibliography

    r5945 r13683  
    77''Revised^5 Report on the Algorithmic Language Scheme'' [[http://www.schemers.org/Documents/Standards/R5RS]]
    88
     9---
    910Previous: [[Acknowledgements]]
  • chicken/trunk/manual/Bugs and limitations

    r5945 r13683  
    1111* Leaf routine optimization can theoretically result in code that thrashes, if tight loops perform excessively many mutations.
    1212
     13---
    1314Previous: [[Data representation]]
    1415
  • chicken/trunk/manual/C interface

    r13580 r13683  
    392392
    393393
    394 
     394---
    395395Previous: [[Other support procedures]]
    396396
  • chicken/trunk/manual/Callbacks

    r13580 r13683  
    9494that the value pointed to by {{ptr}} is located in the stack.
    9595
     96---
    9697Previous: [[Embedding]]
    9798
  • chicken/trunk/manual/Data representation

    r11842 r13683  
    113113For more information see the header file {{chicken.h}}.
    114114
     115---
    115116Previous: [[Extensions]]
    116117
  • chicken/trunk/manual/Declarations

    r12595 r13683  
    322322knows about them.
    323323
     324---
    324325Previous: [[Modules and macros]]
    325326
  • chicken/trunk/manual/Deviations from the standard

    r10952 r13683  
    44
    55Identifiers are by default case-sensitive (see
    6 [[http://galinha.ucpel.tche.br:8080/Using%20the%20compiler#Compiler%20command%20line%20format|Compiler
    7 command line format]]).
     6[[http://galinha.ucpel.tche.br:8080/Using%20the%20compiler#Compiler%20command%20line%20format|Compiler command line format]]).
    87
    98[4.1.3] The maximal number of arguments that may be passed to a
     
    7170not implemented.
    7271
     72---
    7373Previous: [[Supported language]]
    7474
  • chicken/trunk/manual/Embedding

    r12939 r13683  
    335335Sets the value of the global variable referenced by the GC root {{global}} to {{value}}.
    336336
     337---
    337338Previous: [[Foreign type specifiers]]
    338339
  • chicken/trunk/manual/Extensions

    r13452 r13683  
    550550mailing list.
    551551
    552 
     552---
    553553Previous: [[Interface to external functions and variables]]
    554554
  • chicken/trunk/manual/Extensions to the standard

    r13580 r13683  
    163163[6.7] The {{exit}} procedure exits a program right away and does ''not'' invoke pending {{dynamic-wind}} thunks.
    164164
     165---
    165166Previous: [[Deviations from the standard]]
    166167
  • chicken/trunk/manual/Foreign type specifiers

    r6691 r13683  
    279279</td></tr></table>
    280280
     281---
    281282Previous: [[Accessing external objects]]
    282283
  • chicken/trunk/manual/Interface to external functions and variables

    r11842 r13683  
    1111* [[C interface]]                 
    1212
     13---
    1314Previous: [[Supported language]]
    1415
  • chicken/trunk/manual/Locations

    r11646 r13683  
    7777the name of a callback-procedure defined with {{define-external}}.
    7878
     79---
    7980Previous: [[Callbacks]]
    8081
  • chicken/trunk/manual/Modules and macros

    r12495 r13683  
    489489
    490490
     491---
    491492Previous: [[Non-standard macros and special forms]]
    492493
  • chicken/trunk/manual/Non-standard macros and special forms

    r13580 r13683  
    498498and major GCs.
    499499
     500---
    500501Previous: [[Non-standard read syntax]]
    501502
  • chicken/trunk/manual/Non-standard read syntax

    r13580 r13683  
    130130 (cond-expand (FEATURE EXPR) (else))
    131131
     132---
    132133Previous: [[Extensions to the standard]]
    133134
  • chicken/trunk/manual/Other support procedures

    r5945 r13683  
    1111and {{argv}} arguments passed to the current process.
    1212
     13---
    1314Previous: [[Locations]]
    1415
  • chicken/trunk/manual/Parameters

    r13672 r13683  
    125125abort the current computation and to restart the read-eval-print loop.
    126126
    127 
     127---
    128128Previous: [[Declarations]]
    129129
  • chicken/trunk/manual/Supported language

    r11646 r13683  
    2929* [[Unit lolevel]] low-level operations
    3030
     31---
    3132Previous: [[Using the interpreter]]
    3233
  • chicken/trunk/manual/The User's Manual

    r13670 r13683  
    55This is the user's manual for the Chicken Scheme compiler, version 4.0.0x5
    66
    7 ; [[Overview]] : What is CHICKEN and how do I use it?
     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 data-structures

    r12021 r13683  
    618618Returns the index of the found value or {{#f}} otherwise.
    619619
     620---
    620621Previous: [[Unit expand]]
    621622
  • chicken/trunk/manual/Unit eval

    r13580 r13683  
    252252and defaults to the value of {{(interaction-environment)}}.
    253253
    254 
     254---
    255255Previous: [[Unit library]]
    256256
  • chicken/trunk/manual/Unit expand

    r11133 r13683  
    4646{{error}}.
    4747
    48 
     48---
    4949Previous: [[Unit library]]
    5050
  • chicken/trunk/manual/Unit extras

    r13661 r13683  
    805805Returns the index of the found value or {{#f}} otherwise.
    806806
     807---
    807808Previous: [[Unit files]]
    808809
  • chicken/trunk/manual/Unit files

    r13659 r13683  
    139139and fully written but removing {{ORIGFILE}} fails.
    140140
    141 
     141---
    142142Previous: [[Unit ports]]
    143143
  • chicken/trunk/manual/Unit library

    r13659 r13683  
    12291229one element.
    12301230
    1231 
     1231---
    12321232Previous: [[Parameters]]
    12331233
  • chicken/trunk/manual/Unit lolevel

    r13148 r13683  
    789789</enscript>
    790790
    791 
     791---
    792792Previous: [[Unit tcp]]
    793793
  • chicken/trunk/manual/Unit ports

    r13659 r13683  
    140140does not close any of the argument ports.
    141141
    142 
     142---
    143143Previous: [[Unit data-structures]]
    144144
  • chicken/trunk/manual/Unit posix

    r13659 r13683  
    13161316* -1 when failure
    13171317
    1318 
     1318---
    13191319Previous: [[Unit srfi-18]]
    13201320
  • chicken/trunk/manual/Unit regex

    r13659 r13683  
    194194</enscript>
    195195
    196 
     196---
    197197Previous: [[Unit srfi-14]]
    198198
  • chicken/trunk/manual/Unit srfi-1

    r5945 r13683  
    66[[http://srfi.schemers.org/srfi-1/srfi-1.html|SRFI-1]]
    77
     8---
    89Previous: [[Unit extras]]
    910
  • chicken/trunk/manual/Unit srfi-13

    r5945 r13683  
    1414</enscript>
    1515
    16 
     16---
    1717Previous: [[Unit srfi-4]]
    1818
  • chicken/trunk/manual/Unit srfi-14

    r10872 r13683  
    1515This library provides only the Latin-1 character set.
    1616
     17---
    1718Previous: [[Unit srfi-13]]
    1819
  • chicken/trunk/manual/Unit srfi-18

    r13659 r13683  
    100100    (milliseconds->time (+ ms (current-milliseconds)))))
    101101
     102---
    102103Previous: [[Unit regex]]
    103104
  • chicken/trunk/manual/Unit srfi-4

    r5945 r13683  
    157157{{PORT}} defaults to the value of {{(current-output-port)}}.
    158158
    159 
     159---
    160160Previous: [[Unit srfi-1]]
    161161
  • chicken/trunk/manual/Unit tcp

    r13659 r13683  
    207207 Hello!
    208208
     209---
    209210Previous: [[Unit utils]]
    210211
  • chicken/trunk/manual/Unit utils

    r13677 r13683  
    6262port that is the current value of {{(current-input-port)}}.
    6363
     64---
    6465Previous: [[Unit posix]]
    6566
  • chicken/trunk/manual/Using the compiler

    r13672 r13683  
    161161; -prelude EXPRESSIONS : Add {{EXPRESSIONS}} before all other toplevel expressions in the compiled file.  This option may be given multiple times. Processing of this option takes place before processing of {{-prologue}}.
    162162
    163 ; -profile :
     163; -profile : 
    164164;-accumulate-profile : Instruments the source code to count procedure calls and execution times. After the program terminates (either via an explicit {{exit}} or implicitly), profiling statistics are written to a file named {{PROFILE}}. Each line of the generated file contains a list with the procedure name, the number of calls and the time spent executing it. Use the {{chicken-profile}} program to display the profiling information in a more user-friendly form. Enter {{chicken-profile}} with no arguments at the command line to get a list of available options. The {{-accumulate-profile}} option is similar to {{-profile}}, but the resulting profile information will be appended to any existing {{PROFILE}} file. {{chicken-profile}} will merge and sum up the accumulated timing information, if several entries for the same procedure calls exist.
    165165
     
    438438contact with the author.
    439439
     440---
    440441Previous: [[The User's Manual]]
    441442
  • chicken/trunk/manual/Using the interpreter

    r13672 r13683  
    258258Note: Currently the documentation provided by the {{man}} extension corresponds to Chicken's 2.429, one of the last releases whose documentation was in the texinfo format (the format the {{man}} extension parses).
    259259
    260 ----
    261 
     260---
    262261Previous: [[Using the compiler]]
    263262
  • chicken/trunk/manual/faq

    r13659 r13683  
    626626connection to the egg repository. Try disabling the firewall temporarily.
    627627
    628 ----
    629 
     628---
    630629Previous: [[Bugs and limitations]]
    631630
  • chicken/trunk/scripts/wiki2html.scm

    r13669 r13683  
    1010;;; inline elements
    1111
    12 (define +code+ '(: #\{ #\{ (submatch (* (~ #\}))) #\} #\}))
     12(define +code+ '(: #\{ #\{ (submatch (*? (~ #\}))) #\} #\}))
    1313(define +bold+ '(: (= 3 #\') (submatch (* (~ #\'))) (= 3 #\')))
    1414(define +italic+ '(: (= 2 #\') (submatch (* (~ #\'))) (= 2 #\')))
     
    2222  `(or ,+code+ ,+link+ ,+html-tag+ ,+bold+ ,+italic+))
    2323
     24(define +http-url+ '(: (* space) "http://" (* any)))
     25
    2426
    2527;;; Block elements
     
    2729(define +header+ '(: (submatch (>= 2 #\=)) (* space) (submatch (* any))))
    2830(define +pre+ '(: (>= 1 space) (submatch (* any))))
    29 (define +d-list+ '(: (* space) #\; (submatch (* (~ #\:))) #\: (submatch (* any))))
     31(define +d-list+ '(: (* space) #\; (submatch (*? any)) #\space #\: #\space (submatch (* any))))
    3032(define +u-list+ '(: (* space) (submatch (>= 1 #\*)) (* space) (submatch (* any))))
    3133(define +o-list+ '(: (* space) (submatch (>= 1 #\*)) #\# (* space) (submatch (* any))))
     
    4648(define *open* '())
    4749(define *manual-pages* '())
     50(define *list-continuation* #f)
    4851
    4952(define (push-tag tag out)
     53  ;(fprintf (current-error-port) "start: tag: ~a, open: ~a~%" tag *open*)
    5054  (unless (and (pair? *open*) (equal? tag (car *open*)))
    5155    (when (pair? *open*)
    52       (pop-tag out))
    53     (fprintf out "<~a>~%" (if (pair? tag) (car tag) tag))
    54     (set! *open* (cons tag *open*))))
     56      (cond ((not (pair? tag)) (pop-tag out))
     57            ((pair? (car *open*))
     58             ;(fprintf (current-error-port) "tag: ~a, open: ~a~%" tag *open*)
     59             (when (< (cdr tag) (cdar *open*))
     60               (do ((n (cdar *open*) (sub1 n)))
     61                   ((= (cdr tag) n))
     62                 (pop-tag out))))))
     63    (unless (and (pair? *open*) (equal? tag (car *open*)))
     64      (fprintf out "<~a>~%" (if (pair? tag) (car tag) tag))
     65      (set! *list-continuation* #f)
     66      ;(fprintf (current-error-port) "PUSH: ~a~%" tag)
     67      (set! *open* (cons tag *open*)))))
    5568
    5669(define (pop-tag out)
    5770  (let ((tag (car *open*)))
     71    ;(fprintf (current-error-port) "POP: ~a~%" *open*)
    5872    (fprintf out "</~a>~%" (if (pair? tag) (car tag) tag))
    5973    (set! *open* (cdr *open*))))
     
    8195         (cond ((eof-object? ln) (return #f))
    8296               ((not (string-match (rx +block-element+) ln))
    83                 (cond ((string-null? ln) (display "<br />\n" out))
     97                (cond ((string-null? ln)
     98                       (display "<br />\n" out)
     99                       (set! *list-continuation* #f))
    84100                      (else
    85101                       (pop-all out)
     
    94110               ((string-match (rx +pre+) ln) =>
    95111                (lambda (m)
    96                   (push-tag 'pre out)
    97                   (fprintf out "~a~%" (clean (car m)))))
     112                  (cond (*list-continuation*
     113                         (fprintf out "~a~%" (inline (second m))))
     114                        (else
     115                         (push-tag 'pre out)
     116                         (fprintf out "~a~%" (clean (car m)))))))
    98117               ((string-match (rx +hr+) ln) =>
    99118                (lambda (m)
     
    102121                (lambda (m)
    103122                  (push-tag 'dl out)
     123                  (set! *list-continuation* #t)
    104124                  (fprintf out "<dt>~a</dt><dd>~a</dd>~%"
    105125                           (inline (second m)) (inline (third m)))))
     
    107127                (lambda (m)
    108128                  (push-tag `(ul . ,(string-length (second m))) out)
     129                  (set! *list-continuation* #t)
    109130                  (fprintf out "<li>~a~%" (inline (third m)))))
    110131               ((string-match (rx +o-list+) ln) =>
    111132                (lambda (m)
    112133                  (push-tag `(ol . ,(string-length (second m))) out)
     134                  (set! *list-continuation* #t)
    113135                  (fprintf out "<li>~a~%" (inline (third m)))))
    114136               (else (error "unknown block match" m))Ž)
     
    144166                             ((member m1 *manual-pages*)
    145167                              (string-append
    146                                "<a href='" (clean m1) ".html'>" (clean m1) "</a>"))
     168                               "<a href='" (clean m1) ".html'>" (inline m1) "</a>"))
    147169                             (else
    148170                              (string-append
    149                                "<a href='" (clean (second m)) "'>"
     171                               "<a href='"
     172                               (clean
     173                                (let ((href (second m)))
     174                                  (if (string-match (rx +http-url+) href)
     175                                      href
     176                                      (string-append "http://chicken.wiki.br/" href))))
     177                               "'>"
    150178                               (clean (or (third m) (second m)))
    151179                               "</a>")))
     
    182210    (display
    183211     (shtml->html
    184       (wrap name (walk `(body ,@(cdr sxml))))))))
     212      (let ((sxml (wrap name (walk `(body ,@(cdr sxml))))))
     213        ;(pp sxml (current-error-port))
     214        sxml)))))
    185215
    186216(define (wrap name body)
    187   `(html (head (title ,(string-append "The CHICKEN User's Manual - " name)))
     217  `(html (head (title ,(string-append "The CHICKEN User's Manual - " name))
     218               (style (@ (type "text/css"))
     219                 "@import url('manual.css');\n"))
    188220         ,body))
    189221
Note: See TracChangeset for help on using the changeset viewer.