This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch 4/3] Header file reduction - Tools for contrib


On 10/06/2015 08:02 AM, Bernd Schmidt wrote:

There are 9 tools I used over the run of the project.  They were
developed in various stages and iterations, but I tried to at least have
some common interface things, and I tried some cleaning up and
documentation.

I'll probably have to make multiple passes over this. A disclaimer first, I have done enough Python programming to develop a dislike for the language, but not enough to call myself an expert.

General comments first. Where applicable, I think we should apply the same coding standards to Python as we do for C/C++. That means things like function comments documenting parameters. They are absent for the most part in this patch, and I won't point out individual instances. Also, I think the documentation should follow our usual rules. There are spelling and grammar problems. I will point out what I find (only the first instance for recurring problems), but please proofread the whole thing for the next submission. The Thunderbird spellchecker actually is pointing out a lot of these. Capitalize starts of sentences, write full sentences and terminate with punctuation.


I primarily submitted it early because you wanted to look at the tools before the code patch, which is the one I care about since the longer it goes, the more effort it is to update the patch to mainline. I apologize for not proofreading it as much as I usually do. My longer term intention was to polish the readme stuff and put it into each tool as well.

however, none of the other tools or scripts in contrib subscribe to commenting every function the same as we do for c/c++. I did put comments in many places where it wasn't obvious what was going on to help with readability, but other cases it seemed obvious enough not to bother. I don't mind adding missing ones that are important, but I do not see why every function needs to have the full c/c++ coding standard applied to it when no other tool does. These certainly appear as good to me if not better than the existing scripts...


No commenting on the quality of python code... :-) I was
learning python on the fly.    Im sure some things are QUITE awful.,

Yeah, the general impression is of fairly ad-hoc code. Not sure how much can be done about this.
they were never intended as general purpose tools, they were developed over multiple iterations and bugfixing and never properly designed.. they were never originally intended for public submission, so they suffer... and I'm not interested in rewriting them yet again

Andrew


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]