From f74e186350891f58d0716feaacba9cf4d4ad76b0 Mon Sep 17 00:00:00 2001 From: Chris Hanson Date: Thu, 15 Jan 2004 20:59:12 +0000 Subject: [PATCH] Implement %STRING->SYMBOL for to eliminate unnecessary copying in parser. --- v7/src/runtime/symbol.scm | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/v7/src/runtime/symbol.scm b/v7/src/runtime/symbol.scm index b4cbf6e57..0739f7654 100644 --- a/v7/src/runtime/symbol.scm +++ b/v7/src/runtime/symbol.scm @@ -1,8 +1,8 @@ #| -*-Scheme-*- -$Id: symbol.scm,v 1.13 2003/09/24 19:21:58 cph Exp $ +$Id: symbol.scm,v 1.14 2004/01/15 20:59:12 cph Exp $ -Copyright 1992,1993,2001,2003 Massachusetts Institute of Technology +Copyright 1992,1993,2001,2003,2004 Massachusetts Institute of Technology This file is part of MIT/GNU Scheme. @@ -63,6 +63,10 @@ USA. (or ((ucode-primitive find-symbol) string) ((ucode-primitive string->symbol) (string-copy string)))) +(define (%string->symbol string) + (or ((ucode-primitive find-symbol) string) + ((ucode-primitive string->symbol) string))) + (define (substring->symbol string start end) ((ucode-primitive string->symbol) (substring string start end))) -- 2.25.1