0

Possible Duplicate:
Forward declarations in bash?

I have lot many functions in a shell script source file in which one calls other so Always I have to place the functions in the correct order.

Isn't there any thing like forward declaration of function in shell script as we have in C/C++ ?

EDIT : Or, is there any way to implement it ?

Community
  • 1
  • 1
Omkant
  • 9,018
  • 8
  • 39
  • 59
  • 2
    AFAIK, forward declarations aren't necessary at all. As long as you don't use a function before all its dependencies have been read by the shell. – Mat Dec 20 '12 at 14:33
  • @Mat : if not then suppose i am calling one function from other and definition of that function below it then it throws an error – Omkant Dec 20 '12 at 14:36

0 Answers0