[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug-gnulib] Re: [PATCH]: fix warning in the hash module
From: |
Jim Meyering |
Subject: |
[bug-gnulib] Re: [PATCH]: fix warning in the hash module |
Date: |
Tue, 17 May 2005 14:21:42 +0200 |
Yoann Vandoorselaere <address@hidden> wrote:
>> > This patch fix constness warning in the GnuLib hash module.
That patch fixes three of the four warnings produced by gcc -Wcast-qual.
The final one is here:
void *
hash_insert (Hash_table *table, const void *entry)
{
...
return (void *) entry; <<<=======
}
What's the gain in fixing three of them if one still remains?
That last one looks unavoidable, given my requirement that the
second parameter retain the `const' attribute.
FYI, there are similar const-removing casts in many other modules.
Look at all of the functions like memchr, memmem, strdup, etc.,
that take a const string and return a non-const pointer into that
same string.
- [bug-gnulib] [PATCH]: fix warning in the hash module, Yoann Vandoorselaere, 2005/05/17
- [bug-gnulib] Re: [PATCH]: fix warning in the hash module, Jim Meyering, 2005/05/17
- [bug-gnulib] Re: [PATCH]: fix warning in the hash module, Yoann Vandoorselaere, 2005/05/17
- [bug-gnulib] Re: [PATCH]: fix warning in the hash module, Ian Abbott, 2005/05/18
- Re: [bug-gnulib] Re: [PATCH]: fix warning in the hash module, Yoann Vandoorselaere, 2005/05/18
- [bug-gnulib] Re: [PATCH]: fix warning in the hash module, Ian Abbott, 2005/05/19
- [bug-gnulib] Re: [PATCH]: fix warning in the hash module, Yoann Vandoorselaere, 2005/05/19
- [bug-gnulib] Re: [PATCH]: fix warning in the hash module, Ian Abbott, 2005/05/19