On Friday 19 September 2008 16:44:22 Daniel Jacobowitz wrote: > It looks like you don't have a copyright assignment or employer > disclaimer on file. Is that correct? If so, we should sort it out > now before you contribute anything larger. Working on that already. Might take a while, though. The stuff in question is certainly well below any reasonable threshold of "original art", though, but I see the problem. > > I hope this is uncontroversial, but before going further into this > > direction I have two related questions: > > > > 1. How would the prefered way to call, say, xfree on a 'conceptionally const > > char *' item look like? Are casts to non-const (void *) acceptable > > here? > > Probably acceptable, but if you know it is allocated by xfree, should > it really be returned as const? The problem will come up with "char *" struct members pointing to "names" of all sorts. They could arguably be "const char *" as they usually aren't touched between construction and destruction to get a compiler warning if something tries to modify them nevertheless. But then, those members could stay non-const... > > the work. Are there any shortcuts available/acceptable? > > If you have to update the call sites, you can say "all callers > updated" or something like that in the changelog entry, though if any > of the changes are more than mechanical then it's better to list > the complicated ones explicitly. But for just a change to a prototype > and a definition, I think the changelog entry is still appropriate. > > BTW, your changelog is too verbose in another way; there is normally > only one starred entry for a file and you can combine similar changes. > Like this: > > * symfile.c (allocate_symtab, allocate_psymtab, free_named_symtabs) > (deduce_language_from_filename): Accept a const argument. Ok. > Please use diff -up for patches; with the default diff arguments, it's > impossible to see what you've changed. I intented to do that but I somehow fumbled. Next try attached. Andre'