Path: csiph.com!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!newsfeed101.telia.com!starscream.dk.telia.net!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail From: Ian Collins Newsgroups: comp.programming Subject: Re: programmer's keyboard Date: Sun, 30 Dec 2012 10:43:15 +1300 Lines: 43 Message-ID: References: <150e1c64-726a-43cc-82f9-a52c81a2e8ce@googlegroups.com> <_sWdnYhcjvIJl0LNnZ2dnUVZ8sadnZ2d@bt.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: individual.net SYggHeeu/BGBRloK8g0gTQh7CEyCNtShpCBuVdSHMdBVayTBY1+TlN5XmIxCJCDx9/ Cancel-Lock: sha1:ctxjvKDOhbAWpQB48LsRv1SQwQo= User-Agent: Mozilla/5.0 (X11; SunOS i86pc; rv:17.0) Gecko/17.0 Thunderbird/17.0 In-Reply-To: Xref: csiph.com comp.programming:2685 BGB wrote: > On 12/29/2012 9:15 AM, Chris Uppal wrote: >> BartC wrote: >> >>> (And I also like writing temporary code such as that in capitals. You >>> can't do that in a case-sensitive language (without creating duplicate >>> upper-case versions of keywords and identifiers).) >> >> Then you're out of luck, if you're using a C-family language ;-) >> >> I like to flag that kind of temporary code by indenting it to column 0. Try >> it, you might like it. >> >> (You can tell I'm not a Pythonista...) >> > > depending on language, it is often something like: > #if 1 > or: > #if true > or: > if(true) { ... } > or similar... > > this basically allows readily turning the code on or off, and indicates > that it is probably temporary or experimental. Independent of the language, just use your version control tool rather than muck about with conditional compiles. Plenty of editors are version control and will mark or highlight code changes. > if code like this is disabled, and proves unlikely to be ever enabled > again, it may later be removed. So just do a revert and its gone.... > if the code essentially becomes permanent and/or required, then the > markers will (usually) eventually be removed. ...or check it in if you want to keep it. -- Ian Collins