undefined method `*' for nil:NilClass

Discussion in 'Ruby' started by Atul Dongargaonkar, Oct 7, 2010.

  1. Atul Dongargaonkar, Oct 7, 2010
    #1
    1. Advertising

  2. Atul Dongargaonkar wrote:
    > Please find the .txt file attached. Am getting the following error
    > message. Please help!
    >
    >
    >
    > Error Loading File slab.rb
    > undefined method `*' for nil:NilClass


    You need to give the *full* error, which includes the line at which the
    error occurred, and the backtrace. Then show what line that line number
    corresponds to.

    You've posted a large amount of code, but for me it's not even runnable
    - the first line calls a method "file_loaded?" which on my system (ruby
    1.8.7) doesn't exist.

    So if you cannot boil this down to a five-line standalone test program,
    then you must at least show the exact error and context.

    Also, what ruby type and version are you using, and on what platform?
    --
    Posted via http://www.ruby-forum.com/.
     
    Brian Candler, Oct 7, 2010
    #2
    1. Advertising

  3. Brian Candler wrote:
    > Atul Dongargaonkar wrote:
    >> Please find the .txt file attached. Am getting the following error
    >> message. Please help!
    >>
    >>
    >>
    >> Error Loading File slab.rb
    >> undefined method `*' for nil:NilClass

    >
    > You need to give the *full* error, which includes the line at which the
    > error occurred, and the backtrace. Then show what line that line number
    > corresponds to.
    >
    > You've posted a large amount of code, but for me it's not even runnable
    > - the first line calls a method "file_loaded?" which on my system (ruby
    > 1.8.7) doesn't exist.
    >
    > So if you cannot boil this down to a five-line standalone test program,
    > then you must at least show the exact error and context.
    >
    > Also, what ruby type and version are you using, and on what platform?



    Thanks for your reply. Fortunately I somehow managed to debug the error.
    The sad part was there was no mention of the line in which error
    occured! All that was posted is "
    >> Error Loading File slab.rb
    >> undefined method `*' for nil:NilClass"

    I am using Ruby 1.8.6 on Windows 7 (64 bit)by the way...
    --
    Posted via http://www.ruby-forum.com/.
     
    Atul Dongargaonkar, Oct 8, 2010
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Petrucci Fabio
    Replies:
    1
    Views:
    115
    Jim Weirich
    Jul 13, 2004
  2. Petrucci Fabio
    Replies:
    1
    Views:
    121
    Jim Weirich
    Jul 13, 2004
  3. Petrucci Fabio
    Replies:
    0
    Views:
    96
    Petrucci Fabio
    Jul 13, 2004
  4. Giacecco
    Replies:
    0
    Views:
    157
    Giacecco
    Jan 27, 2006
  5. Paatsch, Bernd
    Replies:
    1
    Views:
    152
Loading...

Share This Page