v4.60 StrCmp (String lib) issue (Solved in v4.80 bèta)

Beta Testing discussion on mikroPascal PRO for PIC.
Post Reply
Author
Message
Dany
Posts: 3854
Joined: 18 Jun 2008 11:43
Location: Nieuwpoort, Belgium
Contact:

v4.60 StrCmp (String lib) issue (Solved in v4.80 bèta)

#1 Post by Dany » 28 Dec 2010 17:06

Hi, I think there is a problem with "strcmp" from the "Strings" lib (seen in the simulator).
This is some test code:

Code: Select all

program Test_StrCmp;
var I: integer;

begin 
  I := StrCmp('1234567890',  '12345678901'); // StrCmp returns zero <---- error here (second string larger)
  I := StrCmp('12345678901', '1234567890');  // StrCmp returns 49 (ok)
  I := StrCmp('1234567891',  '1234567890');  // StrCmp returns 1  (ok)
  I := StrCmp('1234567890',  '1234567891');  // StrCmp returns -1 (ok)
end.
Thanks in advance! :D :D
Last edited by Dany on 12 Apr 2011 19:32, edited 2 times in total.
Kind regards, Dany.
Forget your perfect offering. There is a crack in everything, that's how the light gets in... (L. Cohen)
Remember when we were young? We shone like the sun. (David Gilmour)

User avatar
slavisa.zlatanovic
mikroElektronika team
Posts: 1321
Joined: 07 Apr 2009 09:39

Re: v4.60 StrCmp (String lib) issue

#2 Post by slavisa.zlatanovic » 28 Jan 2011 14:53

Hi!

Sorry for the late response.
I've managed to reproduce the issue you reported.
It will be fixed in the next compiler version.
Sorry for the inconvenience.
Best regards
Slavisa

Dany
Posts: 3854
Joined: 18 Jun 2008 11:43
Location: Nieuwpoort, Belgium
Contact:

Re: v4.60 StrCmp (String lib) issue, Solved in v4.80 bèta

#3 Post by Dany » 12 Apr 2011 19:29

Issue solved in mP 4.80 bèta.

Thanks mE guys! Good work. :D :D :D
Kind regards, Dany.
Forget your perfect offering. There is a crack in everything, that's how the light gets in... (L. Cohen)
Remember when we were young? We shone like the sun. (David Gilmour)

Post Reply

Return to “mikroPascal PRO for PIC Beta Testing”