Changeset 13813 in project


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

added test scripts

Location:
chicken/trunk
Files:
2 added
2 edited

Legend:

Unmodified
Added
Removed
  • chicken/trunk/distribution/manifest

    r13735 r13813  
    209209tests/r4rstest.out
    210210tests/port-tests.scm
    211 tests/test-gc-hook.scm
     211tests/test-gc-hooks.scm
    212212tests/matchable.scm
    213213tests/match-tests.scm
    214214tests/module-tests.scm
    215215tests/test-finalizers.scm
     216tests/test-finalizers-2.scm
    216217tests/module-tests-compiled.scm
    217218tests/syntax-tests.scm
  • chicken/trunk/manual/faq

    r13710 r13813  
    105105==== Does CHICKEN support Unicode strings?
    106106
    107 Yes, as an extension.
    108 
    109 By default all string and character functions operate bytewise, so that characters with an iteger value greater than 255 don't make much sense and multibyte UTF-8 characters are seen and manipulated as separate bytes, analogous to what a C program would see.
    110 
    111 You can enable UTF-8 support by placing the following two lines at the beginning of your source file (or in your ~/.csirc for interactive sessions) before any other code, including other use directives:
    112 
    113 <enscript highlight=scheme>
    114 (use iset syntax-case utf8)
    115 (import utf8)
    116 </enscript>
    117 
    118 This will replace all builtin string operators with UTF-8-aware versions, that will treat strings as sequences of multibyte UTF-8 characters, thus enabling you to represent and manipulate Unicode characters while remaining compatible with most C libraries and system interfaces.
    119 
    120 Most eggs should work correctly in utf8 mode, including the regex extension, but you still have the option of working around incompatibilities of specific eggs by loading them before the (import utf8) directive. Keep in mind that some operations, such as string-length, are much more expensive in utf8 (multibyte) mode, and should be used with care. See the [[http://www.call-with-current-continuation.org/eggs/utf8.html|utf8 egg documentation]] for details.
    121 
     107The system does not directly support Unicode, but an extension for UTF8 strings
     108exists for CHICKEN 3, which may be ported to the current CHICKEN version at some
     109stage.
    122110
    123111=== Why are `dynamic-wind' thunks not executed when a SRFI-18 thread signals an error?
     
    250238
    251239
    252 === Compiled macros
     240=== Macros
     241
     242==== Where is {{define-macro}}?
     243
     244With CHICKEN 4, the macro-expansion subsystem is now hygienic where old Lisp-style low-level macros
     245are not available anymore. {{define-syntax}} can define hygienic macros using {{syntax-rules}}
     246or low-level macros with user-controlled hygienic with ''explicit renaming'' macros. Translating
     247old-style macros into ER-macros isn't that hard, see [[Modules and macros]] for more information.
    253248
    254249==== Why are low-level macros defined with {{define-syntax}} complaining about unbound variables?
     
    260255
    261256During compile-time, macros are only available in the source file in which they are defined. Files included via {{include}} are considered part of the containing file.
    262 
    263 ==== Why is {{include}} unable to load my hygienic macros?
    264 
    265 It is not sufficient for the included file to require the {{syntax-case}} extension. Call {{(require-extension syntax-case)}} ''before'' calling {{include}}.
    266257
    267258=== Warnings and errors
     
    490481which point {{foo.scm}} will no longer be required).
    491482
     483==== Why is my program which uses regular expressions so slow?
     484
     485The regular expression engine has recently be replaced by [[alex shinn]]'s excellent
     486{{irregex}} library, which is fully implemented in Scheme. Precompiling regular
     487expressions to internal form is somewhat slower than with the old PCRE-based
     488regex engine. It is advisable to use {{regexp}} to precompile regular expressions
     489outside of time-critical loops and use them where performance matters.
     490
     491
    492492=== Garbage collection
    493493
Note: See TracChangeset for help on using the changeset viewer.