Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!purdue!ames!elroy!usc!orion.cf.uci.edu!uci-ics!schmidt From: schmidt@ics.uci.edu (Doug Schmidt) Newsgroups: gnu.g++.lib.bug Subject: Re: (none) Message-ID: <16956@paris.ics.uci.edu> Date: 7 Jun 89 03:25:41 GMT References: <8906062051.AA06600@nueng.> Sender: news@paris.ics.uci.edu Reply-To: Doug Schmidt Distribution: gnu Organization: University of California at Irvine: ICS Dept. Lines: 42 In article <8906062051.AA06600@nueng.> saini@nueng.ai.mit.edu (Riju Saini) writes: ++ ++ Hi, ++ I am not sure if this is the right place to report bugs that I ++ found in `gperf'. I am sending it here in the hope that it ++ will be noticed by someone. Hi Riju, This is indeed the place to send gperf bugs. ++ (1) The tests provided with cperf ran perfectly, but on experimenting ++ with some of the command line switches I found gperf to generate ++ incorrect C code for the `wordlist' structure initialization. ++ Any combination of the '-t -p' switchs with the '-D' switch produces ++ this error. Part of the (error) output generated on the `c-parse.gperf' ++ file is given below: That is indeed a bug. I've fixed it in the next release. ++ (2) This is not a bug, but more like a suggestion for maybe an ++ extra option... ++ I find the use of the string comparison function `strncmp' better ++ (under certain conditions) justified than using `strcmp'. Since ++ the length of the string is always passed to `in_word_set' this ++ can be implimented with relative ease, or provided as a command ++ line option. I find the use of `strncmp' specially attractive when ++ I want to pickup keywords from *one* large string, the keyword ++ lengths being fixed. For example: I am trying to parse a chemical That sounds reasonable. I'll add that to the (growing) list of gperf options. If anyone else has any suggestions for gperf modifications please forward them to me at schmidt@ics.uci.edu. thanks, Doug -- Any man's death diminishes me, | schmidt@ics.uci.edu (ARPA) Because I am involved in Mankind; | office: (714) 856-4043 And therefore never send to know for whom the bell tolls; It tolls for thee -- John Donne