Changeset 29118 in project


Ignore:
Timestamp:
06/18/13 11:35:22 (8 years ago)
Author:
felix winkelmann
Message:

utf8 3.3.7: (utf8-case-map) emit warning if case-map files can not be found

Location:
release/4/utf8
Files:
4 edited
1 copied

Legend:

Unmodified
Added
Removed
  • release/4/utf8/tags/3.3.7/utf8-case-map.scm

    r26978 r29118  
    9797
    9898(define *char-case-table-1*
    99   (condition-case
    100     (and-let* ((file (find-data-file *char-case-file-1*))
    101                (size (file-size file))
    102                (vec (make-u32vector (quotient size 4))))
    103       (call-with-input-file file
    104         (cut read-block! vec <>))
    105       vec)
    106     (var ()
    107       (warning "couldn't load case-map-1.dat")
    108       (make-u32vector 0))))
     99  (or (condition-case
     100          (and-let* ((file (find-data-file *char-case-file-1*))
     101                     (size (file-size file))
     102                     (vec (make-u32vector (quotient size 4))))
     103            (call-with-input-file file
     104              (cut read-block! vec <>))
     105            vec)
     106        (var () #f))
     107      (begin
     108        (warning "couldn't load case-map-1.dat")
     109        (make-u32vector 0))))
    109110
    110111(define *char-case-count-1*
     
    160161
    161162(define *char-case-table-2*
    162   (condition-case
    163     (with-input-from-file (find-data-file *char-case-file-2*) read)
    164     (var ()
    165       (warning "couldn't load case-map-2.dat")
    166       '#())))
     163  (or (and-let* ((file (find-data-file *char-case-file-2*)))
     164        (condition-case
     165            (with-input-from-file file read)
     166          (var () #f)))
     167      (begin
     168        (warning "couldn't load case-map-2.dat")
     169        '#())))
    167170
    168171(define *char-case-length-2* (vector-length *char-case-table-2*))
  • release/4/utf8/tags/3.3.7/utf8.setup

    r27760 r29118  
    22(use make)
    33
    4 (define version "3.3.6")
     4(define version "3.3.7")
    55
    66(make (("utf8-lolevel.so" ("utf8-lolevel.scm")
  • release/4/utf8/trunk/utf8-case-map.scm

    r26978 r29118  
    9797
    9898(define *char-case-table-1*
    99   (condition-case
    100     (and-let* ((file (find-data-file *char-case-file-1*))
    101                (size (file-size file))
    102                (vec (make-u32vector (quotient size 4))))
    103       (call-with-input-file file
    104         (cut read-block! vec <>))
    105       vec)
    106     (var ()
    107       (warning "couldn't load case-map-1.dat")
    108       (make-u32vector 0))))
     99  (or (condition-case
     100          (and-let* ((file (find-data-file *char-case-file-1*))
     101                     (size (file-size file))
     102                     (vec (make-u32vector (quotient size 4))))
     103            (call-with-input-file file
     104              (cut read-block! vec <>))
     105            vec)
     106        (var () #f))
     107      (begin
     108        (warning "couldn't load case-map-1.dat")
     109        (make-u32vector 0))))
    109110
    110111(define *char-case-count-1*
     
    160161
    161162(define *char-case-table-2*
    162   (condition-case
    163     (with-input-from-file (find-data-file *char-case-file-2*) read)
    164     (var ()
    165       (warning "couldn't load case-map-2.dat")
    166       '#())))
     163  (or (and-let* ((file (find-data-file *char-case-file-2*)))
     164        (condition-case
     165            (with-input-from-file file read)
     166          (var () #f)))
     167      (begin
     168        (warning "couldn't load case-map-2.dat")
     169        '#())))
    167170
    168171(define *char-case-length-2* (vector-length *char-case-table-2*))
  • release/4/utf8/trunk/utf8.setup

    r27760 r29118  
    22(use make)
    33
    4 (define version "3.3.6")
     4(define version "3.3.7")
    55
    66(make (("utf8-lolevel.so" ("utf8-lolevel.scm")
Note: See TracChangeset for help on using the changeset viewer.