How do you flag code so that you can come back later and work on it?

前端 未结 23 2343
后悔当初
后悔当初 2020-12-24 11:46

In C# I use the #warning and #error directives,

#warning This is dirty code...
#error Fix this before everything explodes!
<         


        
23条回答
  •  情深已故
    2020-12-24 12:12

    Todo comment as well.

    We've also added a special keyword NOCHECKIN, we've added a commit-hook to our source control system (very easy to do with at least cvs or svn) where it scans all files and refuses to check in the file if it finds the text NOCHECKIN anywhere.

    This is very useful if you just want to test something out and be certain that it doesn't accidentaly gets checked in (passed the watchful eyes during the diff of everything thats commited to source control).

提交回复
热议问题