From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Han-Wen Nienhuys Newsgroups: gmane.lisp.guile.devel Subject: Re: Internal visibility Date: Sun, 01 Jun 2008 17:24:23 -0300 Message-ID: References: <87k5i5d6ei.fsf@ossau.uklinux.net> <87y76ksglg.fsf@gnu.org> <8763tomqn7.fsf@ossau.uklinux.net> <87lk2jhp0h.fsf@gnu.org> <87skwrce8y.fsf@ossau.uklinux.net> <87iqxledzz.fsf@gnu.org> <87lk2futg0.fsf@ossau.uklinux.net> <87fxslr1jr.fsf_-_@gnu.org> <878wxv5t7q.fsf@gnu.org> <87mym6dv6t.fsf@gnu.org> Reply-To: hanwen@xs4all.nl NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Trace: ger.gmane.org 1212351954 4470 80.91.229.12 (1 Jun 2008 20:25:54 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 1 Jun 2008 20:25:54 +0000 (UTC) To: guile-devel@gnu.org Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Sun Jun 01 22:26:35 2008 Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1K2u8P-0002ny-2t for guile-devel@m.gmane.org; Sun, 01 Jun 2008 22:26:33 +0200 Original-Received: from localhost ([127.0.0.1]:36984 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1K2u7d-0007UV-0g for guile-devel@m.gmane.org; Sun, 01 Jun 2008 16:25:45 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1K2u7a-0007UC-21 for guile-devel@gnu.org; Sun, 01 Jun 2008 16:25:42 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1K2u7Y-0007Te-E9 for guile-devel@gnu.org; Sun, 01 Jun 2008 16:25:41 -0400 Original-Received: from [199.232.76.173] (port=44812 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1K2u7Y-0007Tb-7W for guile-devel@gnu.org; Sun, 01 Jun 2008 16:25:40 -0400 Original-Received: from main.gmane.org ([80.91.229.2]:48701 helo=ciao.gmane.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1K2u7X-0001Qx-NK for guile-devel@gnu.org; Sun, 01 Jun 2008 16:25:40 -0400 Original-Received: from list by ciao.gmane.org with local (Exim 4.43) id 1K2u7T-0006Le-7O for guile-devel@gnu.org; Sun, 01 Jun 2008 20:25:35 +0000 Original-Received: from 201.80.72.52 ([201.80.72.52]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 01 Jun 2008 20:25:35 +0000 Original-Received: from hanwen by 201.80.72.52 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 01 Jun 2008 20:25:35 +0000 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 23 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 201.80.72.52 User-Agent: Thunderbird 2.0.0.14 (X11/20080501) In-Reply-To: <87mym6dv6t.fsf@gnu.org> X-detected-kernel: by monty-python.gnu.org: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.devel:7293 Archived-At: Ludovic Courtès escreveu: > Hi, > > ludo@gnu.org (Ludovic Courtès) writes: > >> I'd like to push the patch within the next few days if nobody complains, >> alright? > > Done! > > Opinions about making `scm_i_{string,symbol}_chars' internal as well? Can someone explain to me why accessing the underlying (const char*) of a string should be internal? If you are writing C++, doing const char* ptr = scm_i_string_chars(scmval); string x(ptr); is the most straightforward and efficient way to create a string. Using the API incurs an additional malloc, memcpy and free. -- Han-Wen Nienhuys - hanwen@xs4all.nl - http://www.xs4all.nl/~hanwen