problem with computed gotos in the debugger

General discussion on mikroC.
Post Reply
Author
Message
gambrose
Posts: 369
Joined: 28 Sep 2004 17:34
Location: uk

problem with computed gotos in the debugger

#1 Post by gambrose » 25 May 2005 23:40

There seems to be a problem with computed gotos in the debugger.

Using this code as an example:

Code: Select all

main ()
{
  PORTC = 0xAA;

  TRISC = 0;

  PCL += 1;
  PORTC = 0xFF;
}
The debugger will get stuck at the PCL += 1; line.
Where as if run on the PIC it will execute the last statement and fully light up PORTC.
Graham Ambrose

pizon
mikroElektronika team
Posts: 823
Joined: 11 Oct 2004 08:53

Re: problem with computed gotos in the debugger

#2 Post by pizon » 26 May 2005 10:04

OK, added to the buglist.
pizon

gambrose
Posts: 369
Joined: 28 Sep 2004 17:34
Location: uk

#3 Post by gambrose » 26 May 2005 10:07

Thank you :)
Graham Ambrose

gambrose
Posts: 369
Joined: 28 Sep 2004 17:34
Location: uk

#4 Post by gambrose » 26 May 2005 13:26

I see you posted the bug thanks.

there is a workaround it is to add one more than you would do for a pic.

As i think the pic implements the PCL after the operation where as i think the debugger must increment it before so this increment gets overwritten.
Graham Ambrose

Post Reply

Return to “mikroC General”