Re: Another bizarre phenomenon
- To: mathgroup at smc.vnet.net
- Subject: [mg51625] Re: [mg51598] Another bizarre phenomenon
- From: DrBob <drbob at bigfoot.com>
- Date: Wed, 27 Oct 2004 23:42:11 -0400 (EDT)
- References: <200410270553.BAA24479@smc.vnet.net>
- Reply-to: drbob at bigfoot.com
- Sender: owner-wri-mathgroup at wolfram.com
Don't use (* comments *). They're not worth all the problems they engender. It's better to modularize the code so that it's self-explanatory and, when that's impossible, precede a Module with a text cell that describes the processing. If you really want comments inside a Module, Block, or other compound statement, put them in quotes and delimit them with semicolons, like this: Block[{a, b}, "I'm gonna add a and b"; a+b ] The "comment" is an expression like any other, but it doesn't do anything. This approach may have speed and memory consequences (possibly), but they will be very slight. Bobby On Wed, 27 Oct 2004 01:53:58 -0400 (EDT), Steve Gray <stevebg at adelphia.net> wrote: > I replaced a 3-letter symbol with another 3-letter symbol, looking at > eachsearch and replacement. All seemed ok. Then I tried to execute the > file and it went nuts. I somehow found that if I removed JUST ONE SPACE > between the Module list of local symbols in a function definition line, > and a comment on the same line, all was OK again. Wow. This happened > at least twice, identically. Any comments? > > Steve Gray > > > > -- DrBob at bigfoot.com www.eclecticdreams.net
- References:
- Another bizarre phenomenon
- From: Steve Gray <stevebg@adelphia.net>
- Another bizarre phenomenon