Freaked out man!

A

Asfand Yar Qazi

Hi,

Its odd - if I place a comment at the end of a program I'm writing,
its ok. If I take out the comment, the program crashes?!

Any ideas why?

p.s. Its a game with lots of system access going on.
 
A

Asfand Yar Qazi

Asfand said:
Hi,

Its odd - if I place a comment at the end of a program I'm writing, its
ok. If I take out the comment, the program crashes?!

Any ideas why?

p.s. Its a game with lots of system access going on.

Basically, I'm doing something like this:

Game::new:)userdir => ".game_0.1",
:datadir => "data") do |game|
game.state_machine.add("1", DefaultState.new)
game.state_machine.add("2", AnotherState.new)
end

<crash at this point>


After executing the block, the game's initialise method goes straight
into the game loop. On exiting the loop (when the game quits)
deinitialisation is performed.

A crash occurs at the shown point.

But if I change the top line to:

g = Game::new:)userdir => ".game_0.1",
:datadir => "data") do |game|
....

Then its OK.

What's going on? Any ideas?
 
N

Nikolai Weibull

* Asfand Yar Qazi said:
Its odd - if I place a comment at the end of a program I'm writing,
its ok. If I take out the comment, the program crashes?!
Any ideas why?

Wow! Thanks for the lengthy description of the problem. We've got 10
people working 24/7 on this one.
nikolai
 
C

Carlos

Hi,

Its odd - if I place a comment at the end of a program I'm writing,
its ok. If I take out the comment, the program crashes?!

Any ideas why?

Maybe you recompiled ruby but forgot to recompile the extensions (?).

--
 
B

Brian Schröder

Hi,

Its odd - if I place a comment at the end of a program I'm writing,
its ok. If I take out the comment, the program crashes?!

Any ideas why?

p.s. Its a game with lots of system access going on.

Please try to cut down your program to a minimal example, and post the minimal example here.

Regards,

Brian
 
A

Asfand Yar Qazi

Brian said:
Please try to cut down your program to a minimal example, and post the minimal example here.

Regards,

Brian

Just to let you know, I cancelled this post after posting - obviously
it didn't get cancelled. That's the thing about usenet. Sorry about
that.
 

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Staff online

Members online

Forum statistics

Threads
474,161
Messages
2,570,892
Members
47,427
Latest member
HildredDic

Latest Threads

Top