Created on 2014-01-15 03:12 by meador.inge, last changed 2022-04-11 14:57 by admin.
Files |
|
|
|
File name |
Uploaded |
Description |
Edit |
patchcheck-clinic.patch |
meador.inge,2014-01-15 03:12 |
review |
|
detect.py |
larry,2014-01-28 08:31 |
Example script that sanity-checks all Clinic blocks in a file. |
|
Messages (5) |
|
|
msg208132 - (view) |
Author: Meador Inge (meador.inge) *  |
Date: 2014-01-15 03:12 |
It has been noted a few times that someone might forget to re-run clinic.py after updating the argument clinic comments. The attached patch adds a new check to patchcheck.py to note when files containing argument clinic comments have been changed. You could take it a step further and deduce if the lines ranges within the comments were actually changed, but let's start out simple. |
|
|
msg208133 - (view) |
Author: Zachary Ware (zach.ware) *  |
Date: 2014-01-15 03:30 |
This could be taken a step further, following the lead of the whitespace fixing checks and just run clinic on files that need it. |
|
|
msg209070 - (view) |
Author: Larry Hastings (larry) *  |
Date: 2014-01-24 13:36 |
Maybe I'm not reading this correctly. It looks like the function returns True if it finds any .c or .h file that contains the string '[clinic input]'. It doesn't seem to only check files that have changed. I was considering adding a checkum for the *input* to the third comment (what I call the "output line"). That would let this checker compute the checksum for the input and output sections and confirm that they match. If the input had changed, the checksum would fail, and you'd know they hadn't run clinic recently. |
|
|
msg209165 - (view) |
Author: Alyssa Coghlan (ncoghlan) *  |
Date: 2014-01-25 08:30 |
Having clinic work like reindent on "make patchcheck" would be very nice. As a second line of defence, we should also have a server side equivalent of the whitespace check as a repo hook in Mercurial (i.e. don't allow a push when clinic output is out of date). |
|
|
msg209511 - (view) |
Author: Larry Hastings (larry) *  |
Date: 2014-01-28 08:31 |
I've attached a script here that uses the new tweaked format of Clinic blocks. The new tweaked format isn't checked in yet--that change is being tracked with #20326. Once that's checked in, though, the attached script will check that both the input and output blocks are unchanged and up-to-date, respectively. |
|
|