Opened 13 years ago

Closed 13 years ago

#7948 closed bug (fixed)

Bogus prototype for string::compare

Reported by: pulkomandy Owned by: nobody
Priority: normal Milestone: R1
Component: System Version: R1/Development
Keywords: Cc:
Blocked By: Blocking:
Platform: All

Description (last modified by pulkomandy)

I noticed the C++ standard has :

int String::compare(size_t pos1, size_t n1, const char* s) const;

While Haiku std/bastring.h declares :

int compare(const char* s, size_t pos1, size_t n1) const;

It is BeOS "legacy" (ie BeOS has the same problem), but it's a bit annoying when trying to write portable C++ code.

Can we do something about it without breaking binary compatibility ?

Change History (3)

comment:1 by pulkomandy, 13 years ago

Description: modified (diff)

comment:2 by bonefish, 13 years ago

Just add the missing overloads. None of them clashes with the incorrect compare().

comment:3 by pulkomandy, 13 years ago

Resolution: fixed
Status: newclosed

Fixed in hrev43023.

Note: See TracTickets for help on using tickets.