Jump to content

  • Log In with Google      Sign In   
  • Create Account

- - - - -

bug with show code line after null pointer exception and "for"


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
3 replies to this topic

#1 FDsagizi   Members   -  Reputation: 514

Like
0Likes
Like

Posted 31 January 2013 - 10:23 PM

Hi smile.png

 

Error:

 

 The script ended with an exception.

    funcf: void startGame(string&inout)

    sect: Start.as

    line: 32

    desc: Null pointer access

 

Code:


class A
{
    int GetCount(){ return 10; }
}


void startGame( string &param )
{


    A @a = null;    // line 23
    
    for( int i=0; i < a.GetCount(); i++ ) // line 25
    {                        
        
        
        
        
        
        int some_val;    // line 32
    }
}
 

 


Edited by FDsagizi, 31 January 2013 - 10:25 PM.


Sponsor:

#2 Andreas Jonsson   Moderators   -  Reputation: 3444

Like
0Likes
Like

Posted 01 February 2013 - 07:16 AM

Thanks. I'll look into this.

 

It seems to be missing a marker in the bytecode to give the correct line number.


AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game

#3 FDsagizi   Members   -  Reputation: 514

Like
0Likes
Like

Posted 01 February 2013 - 10:12 PM

i dont know bug this or not smile.png

 

Unexpected end of file : line 16

 

but need show line 23

 

Code:

 

 

 

void F()
{                // Line 16
    int a1;
    int a2;
    int a3;
    int a4;
    int a5;

    F()   '  ;    // Line 23
}
 


#4 Andreas Jonsson   Moderators   -  Reputation: 3444

Like
0Likes
Like

Posted 11 February 2013 - 04:20 PM

I've fixed the for loop issue in revision 1553.

 

Regards,

Andreas


AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS