summaryrefslogtreecommitdiffstats
path: root/strcase.scm
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@robocracy.org>2017-02-20 00:05:27 -0800
committerBryan Newbold <bnewbold@robocracy.org>2017-02-20 00:05:27 -0800
commitfa3f23105ddcf07c5900de47f19af43d1db1b597 (patch)
treeb2c6cce6b97698098f50cbc78c23fdc0f8d401ab /strcase.scm
parentf24b9140d6f74804d5599ec225717d38ca443813 (diff)
downloadslib-fa3f23105ddcf07c5900de47f19af43d1db1b597.tar.gz
slib-fa3f23105ddcf07c5900de47f19af43d1db1b597.zip
Import Upstream version 2c3upstream/2c3
Diffstat (limited to 'strcase.scm')
-rw-r--r--strcase.scm5
1 files changed, 5 insertions, 0 deletions
diff --git a/strcase.scm b/strcase.scm
index f223527..f2c8331 100644
--- a/strcase.scm
+++ b/strcase.scm
@@ -43,3 +43,8 @@
(define (string-capitalize str)
(string-capitalize! (string-copy str)))
+
+(define string-ci->symbol
+ (if (equal? "a" (symbol->string 'a))
+ (lambda (str) (string->symbol (string-downcase str)))
+ (lambda (str) (string->symbol (string-upcase str)))))