From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18091 invoked by alias); 26 Sep 2007 14:26:06 -0000 Received: (qmail 18060 invoked by uid 22791); 26 Sep 2007 14:26:04 -0000 X-Spam-Check-By: sourceware.org Received: from ics.u-strasbg.fr (HELO ics.u-strasbg.fr) (130.79.112.250) by sourceware.org (qpsmtpd/0.31) with ESMTP; Wed, 26 Sep 2007 14:25:57 +0000 Received: from ICSMULLER (laocoon.u-strasbg.fr [130.79.112.72]) by ics.u-strasbg.fr (Postfix) with ESMTP id 2B61818701E; Wed, 26 Sep 2007 16:30:49 +0200 (CEST) From: "Pierre Muller" To: "'Eli Zaretskii'" , "'Jonas Maebe'" Cc: References: <002f01c80038$5881a880$0984f980$@u-strasbg.fr> <36AA51D7-8F6A-41D6-82F2-5E837D169AB9@freepascal.org> In-Reply-To: Subject: RE: [PATCH] Fix PR pascal/2283 Date: Wed, 26 Sep 2007 14:26:00 -0000 Message-ID: <003801c80049$238c29a0$6aa47ce0$@u-strasbg.fr> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 12.0 Content-Language: en-us Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2007-09/txt/msg00371.txt.bz2 I think that the idea is that these functions are exported and might be used by other similar languages, but that this tiny part is really specific and should not be used in the case it is called by some other language code. c_val_print is used in several other language specific XXX-lang.c files. If pascal_val_print gets used one day by some other language, the behavior would be different for pascal and for XXX language. But I agree that this is all pretty hypothetical for now. Should we remove it altogether? It seems that it is the only location inside pascal specific code where such a test is performed. There are three references to another language (language_cplus) inside p-valprint, but this is because pascal code has no demangler and the C++ demangler is used there. Pierre > -----Original Message----- > From: gdb-patches-owner@sourceware.org [mailto:gdb-patches- > owner@sourceware.org] On Behalf Of Eli Zaretskii > Sent: Wednesday, September 26, 2007 4:08 PM > To: Jonas Maebe > Cc: muller@ics.u-strasbg.fr; gdb-patches@sourceware.org > Subject: Re: [PATCH] Fix PR pascal/2283 > > > Cc: "Pierre Muller" , > > gdb-patches@sourceware.org > > From: Jonas Maebe > > Date: Wed, 26 Sep 2007 16:03:13 +0200 > > > > In fact, I have no idea why that code (in both the Pascal and > > Modula-2 cases) even checks the current language, as those routines > > are obviously language-specific. > > Exactly! If this code is Pascal-specific, you shouldn't be checking > the language at all.