[issue20158] Argument Clinic: add --clean option

2014-01-12 Thread Larry Hastings
Larry Hastings added the comment: You can accomplish that workflow by using the Clinic buffer prototype and moving all your output to the "side". Or by using the "buffer" approach, and stopping when you hit the generated code. One of these might actually happen in Clinic, too, so hang on to

[issue20158] Argument Clinic: add --clean option

2014-01-12 Thread Georg Brandl
Georg Brandl added the comment: Another use case here is if you want to "check" the remaining call sites of (say) PyArg_ParseTuple that aren't generated by clinic. Call it '--remove' if you want, but the functionality should be useful. -- nosy: +georg.brandl __

[issue20158] Argument Clinic: add --clean option

2014-01-07 Thread Larry Hastings
Larry Hastings added the comment: I must admit I am losing patience with this conversation. Argument Clinic is not going to provide an attractively-named option that breaks your build and requires fixing by hand. The bug is closed, the feature is not happening, it's my hope that we can now m

[issue20158] Argument Clinic: add --clean option

2014-01-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: If you ran clinic.py --clean and then not ran clinic.py without --clean, it's *your* fault. And you will noticed this when run make. I have named this option --clean because it is similar to 'make clean' and 'make distclean'. If you want make automatically

[issue20158] Argument Clinic: add --clean option

2014-01-07 Thread Larry Hastings
Larry Hastings added the comment: If you edit the Clinic input and don't run clinic.py on it, it's out-of-date but not broken. If you edit the Clinic output and make a mistake, it's *your* fault. If you ran clinic.py --clean, now you've broken your file *and* the normal Clinic build system an

[issue20158] Argument Clinic: add --clean option

2014-01-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: How it differs from the case when you just edit clinic declaration and *_impl function? Until you run clinic on this source file, it is broken. I see that peoples already confused by Argument Clinic and manually edit generated code. --

[issue20158] Argument Clinic: add --clean option

2014-01-07 Thread Larry Hastings
Larry Hastings added the comment: Consider: if you ran "clinic.py --clean" on a C file, then tried to use "make clinic", the makefile would first try to build the C file. But since the C file is now broken, the make would fail. And you can't use "make clinic" to regenerate the Clinic output.

[issue20158] Argument Clinic: add --clean option

2014-01-07 Thread Larry Hastings
Larry Hastings added the comment: I don't think Argument Clinic should do this. It would leave the file in a broken state. But if it's an option on clinic.py it might tempt somebody into using it, then they'd be confused. If you want this functionality, please hack it up yourself locally. I

[issue20158] Argument Clinic: add --clean option

2014-01-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This would just make sources more readable and editable. While I read, write or edit code, I don't want generated code distract me. -- ___ Python tracker ___

[issue20158] Argument Clinic: add --clean option

2014-01-07 Thread Larry Hastings
Larry Hastings added the comment: I meant, under what circumstances would you want to use this? I don't know why you would ever want --clean. Removing the output from the Argument Clinic blocks would break any file using it. And Argument Clinic is sufficiently fast, if you were worried about

[issue20158] Argument Clinic: add --clean option

2014-01-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: As fast as it is possible. This shouldn't be hard task, Argument Clinic already clean old generated code before inserting new code. -- ___ Python tracker ___

[issue20158] Argument Clinic: add --clean option

2014-01-07 Thread Larry Hastings
Larry Hastings added the comment: When would you want this? -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue20158] Argument Clinic: add --clean option

2014-01-07 Thread Serhiy Storchaka
New submission from Serhiy Storchaka: It will be helpful to add the --clean option for the clinic tool, which removes all Argument Clinic generated code. -- messages: 207515 nosy: larry, serhiy.storchaka priority: normal severity: normal status: open title: Argument Clinic: add --clean