Does this help?
print __LINE__ + 1
> #!/usr/bin/ruby #first line of the program
>
#################################################################################
> # DESCRIPTION : xxxxxxxx
> # AUTHOR : yyyyyyyy
>
#################################################################################
>
> # a sample test function
> def test #8th line of the program
> xxxxxxxxxx; #9th line
> yyyyyyyyyy; #10th line
print __LINE__ + 1
> end #11th line -- function test ends here
>
--
Posted via http://www.ruby-forum.com/.