Changeset 7877 in project


Ignore:
Timestamp:
01/23/08 14:44:26 (12 years ago)
Author:
elf
Message:

made the optimisation i suggested in the previous diff for the new reader
syntax.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • chicken/trunk/library.scm

    r7876 r7877  
    23782378              (unless ##sys#enable-qualifiers
    23792379                (##sys#read-error port "qualified symbol syntax is not allowed" tok) )
    2380               (cond ((equal? "current-line" tok)
    2381                         (##sys#slot port 4))
    2382                     ((equal? "current-file" tok)
    2383                         (port-name port))
    2384               (else
    23852380              (let loop ([i 0])
    2386                 (cond [(fx>= i toklen) (##sys#read-error port "invalid qualified symbol syntax" tok)]
     2381                (cond [(fx>= i toklen)
     2382                          (cond ((equal? "current-line" tok)
     2383                                    (##sys#slot port 4))
     2384                                ((equal? "current-file" tok)
     2385                                    (port-name port))
     2386                                (else
     2387                                    (##sys#read-error port "invalid qualified symbol syntax" tok) )) ]
    23872388                      [(fx= (##sys#byte tok i) (char->integer #\#))
    23882389                       (when (fx> i namespace-max-id-len)
     
    23912392                       (##sys#intern-symbol
    23922393                        (string-append p (##sys#substring tok 0 i) (##sys#substring tok (fx+ i 1) toklen)) ) ]
    2393                       [else (loop (fx+ i 1))] ) ) ) ) ) )
     2394                      [else (loop (fx+ i 1))] ) ) ) )
    23942395
    23952396          (define (resolve-symbol tok)
Note: See TracChangeset for help on using the changeset viewer.