Thread Subject:
Nested functions are evil

Subject: Nested functions are evil

From: Markus

Date: 15 May, 2007 02:59:03

Message: 1 of 1

> I wish I could get the code rewritten without nested functions that
> seem to inherit and pass on variables without properly included in
> the argument lists.

I think the introduction of nested functions to Matlab led to even
more unreadable code. They might be nice to have for a short
three-liner in another function. But excessively used like in the
current contest, they lead to perfect disorientation and mistakes.
You will have to be extremely attentive not to use a variable like i
or m or n that is also used in the parent function, if there are many
nested functions over a large number of lines.

Tags for this Thread

Everyone's Tags:

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Tag Activity for This Thread
Tag Applied By Date/Time
contest Matthew Simoneau 11 Jul, 2007 13:47:21
rssFeed for this Thread

Contact us