From: Eli Zaretskii <eliz@gnu.org>
To: Joel Brobecker <brobecker@adacore.com>
Cc: muller@ics.u-strasbg.fr, gdb-patches@sourceware.org
Subject: Re: [RFA] Handle GPC specific name for main function
Date: Sat, 06 Oct 2007 07:24:00 -0000 [thread overview]
Message-ID: <u7im09043.fsf@gnu.org> (raw)
In-Reply-To: <20071005181620.GB3570@adacore.com> (message from Joel Brobecker on Fri, 5 Oct 2007 11:16:20 -0700)
> Date: Fri, 5 Oct 2007 11:16:20 -0700
> From: Joel Brobecker <brobecker@adacore.com>
> Cc: gdb-patches@sourceware.org
>
> This is mostly OK. I feel like I am being a perfectionist on you,
> and I apologize, but I think I might have missed something that
> feels wrong somehow: You're having to cast your global static const
> char into (char *) inside pascal_main_name. I can tell from the code
> that everything will be fine, but perhaps we could do better. What
> do others think of this cast?
>
> static const char GPC_MAIN_PROGRAM_NAME_1[]
> = "_p__M0_main_program";
>
> char *
> pascal_main_name (void)
> {
> [...]
> return (char *) GPC_MAIN_PROGRAM_NAME_1[];
> }
Yuck! Can't we make pascal_main_name return `const char *'? If not,
why not?
next prev parent reply other threads:[~2007-10-06 7:24 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-03 9:31 Pierre Muller
2007-10-05 18:16 ` Joel Brobecker
2007-10-06 7:24 ` Eli Zaretskii [this message]
2007-10-07 7:17 ` Joel Brobecker
2007-10-07 19:25 ` Eli Zaretskii
2007-10-08 6:35 ` Joel Brobecker
2007-10-08 7:35 ` Pierre Muller
2007-10-08 15:14 ` Joel Brobecker
2007-10-08 15:43 ` [RFA-2] " Pierre Muller
2007-10-08 15:45 ` Pierre Muller
2007-10-08 17:24 ` Joel Brobecker
2007-10-08 18:45 ` Joel Brobecker
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=u7im09043.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=brobecker@adacore.com \
--cc=gdb-patches@sourceware.org \
--cc=muller@ics.u-strasbg.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox