Changeset 36065 in project


Ignore:
Timestamp:
08/08/18 21:54:27 (14 months ago)
Author:
Ivan Raikov
Message:

fmt: enabling unicode module

Location:
release/5/fmt/trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • release/5/fmt/trunk/README.chicken

    r36027 r36065  
    11This egg maintains the wrapper paradigm of the upstream source, using
    22(*-chicken.scm) as wrappers that contain Chicken-specific code.  This
    3 eases syncing with upstream. Unicode support is currently disabled until
    4 the utf-8 egg is ported to CHICKEN 5.
     3eases syncing with upstream.
    54
    65However there are a couple differences to note:
  • release/5/fmt/trunk/fmt-unicode-chicken.scm

    r36027 r36065  
    44;; BSD-style license: http://synthcode.com/license.txt
    55
    6 (require-library srfi-4 fmt utf8-lolevel)
    76
    87(module
     
    109 (unicode-char-width unicode-string-width fmt-unicode)
    1110
    12 (import scheme chicken srfi-4 fmt utf8-lolevel)
     11(import scheme (chicken base) (chicken bitwise) srfi-4 fmt utf8-lolevel)
    1312
    1413;; a condensed non-spacing mark range from UnicodeData.txt (chars with
  • release/5/fmt/trunk/fmt.egg

    r36028 r36065  
    55 (category io)
    66 (author "Alex Shinn")
    7  (dependencies srfi-1 srfi-13 srfi-69)
     7 (dependencies srfi-1 srfi-13 srfi-69 utf8)
    88 (test-dependencies test)
    99 (components
     
    1818             (source "fmt-color-chicken.scm")
    1919             (component-dependencies fmt))
    20   ;; (extension fmt-unicode (source "fmt-unicode-chicken"))
     20  (extension fmt-unicode (source "fmt-unicode-chicken")
     21             (component-dependencies fmt))
    2122  ))
    2223
  • release/5/fmt/trunk/tests/test-fmt.scm

    r36062 r36065  
    4545(test "10" (fmt #f (num 10)))
    4646(test "100" (fmt #f (num 100)))
    47 ;; (test "1e+15" (fmt #f (num 1e+15)))
    48 ;; (test "1e+23" (fmt #f (num 1e+23)))
    49 ;; (test "1.2e+23" (fmt #f (num 1.2e+23)))
    50 ;; (test "1e-5" (fmt #f (num 1e-5)))
    51 ;; (test "1e-6" (fmt #f (num 1e-6)))
    52 ;; (test "1e-7" (fmt #f (num 1e-7)))
    53 ;; (test "2e-6" (fmt #f (num 2e-6)))
     47;(test "1e+15" (fmt #f (num 1e+15)))
     48;(test "1e+23" (fmt #f (num 1e+23)))
     49(test "1.2e+23" (fmt #f (num 1.2e+23)))
     50(test "1e-05" (fmt #f (num 1e-5)))
     51(test "1e-06" (fmt #f (num 1e-6)))
     52(test "1e-07" (fmt #f (num 1e-7)))
     53(test "2e-06" (fmt #f (num 2e-6)))
    5454(test "0" (fmt #f (num 0 2)))
    5555(test "1" (fmt #f (num 1 2)))
     
    8787(test "0.0000040" (fmt #f (num 0.000004 10 7)))
    8888(test "0.00000400" (fmt #f (num 0.000004 10 8)))
    89 ;; (test "0.000004" (fmt #f (num 0.000004)))
     89;(test "0.000004" (fmt #f (num 0.000004)))
    9090
    9191(test "   3.14159" (fmt #f (decimal-align 5 (num 3.14159))))
Note: See TracChangeset for help on using the changeset viewer.