From 99f20fb62217fcac3d092c88fd5063a68e072c6f Mon Sep 17 00:00:00 2001 From: Andy Wingo Date: Mon, 19 May 2008 12:23:46 +0200 Subject: [PATCH] make has-suffix? use string-suffix? * ice-9/boot-9.scm (has-suffix?): Use the core / srfi-13's string-suffix?. --- ice-9/boot-9.scm | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/ice-9/boot-9.scm b/ice-9/boot-9.scm index 32610bbc4..0de82b41f 100644 --- a/ice-9/boot-9.scm +++ b/ice-9/boot-9.scm @@ -569,10 +569,7 @@ #f))))) (define (has-suffix? str suffix) - (let ((sufl (string-length suffix)) - (sl (string-length str))) - (and (> sl sufl) - (string=? (substring str (- sl sufl) sl) suffix)))) + (string-suffix? suffix str)) (define (system-error-errno args) (if (eq? (car args) 'system-error)