[Gambas-user] whats different between "left$" and "left" string functions

PICCORO McKAY Lenz mckaygerhard at ...626...
Mon Dec 14 23:29:48 CET 2015


hi Toby

Jussi has right, the wiki before or after me, has some missing points
to newbie programers

also the http://gambaswiki.org/wiki/lang/replace page has broken
links! around the gb.Case (also info are ambigous)

we think gambas comunity must designate 2 or 3 mens to watchful the
wiki and correct that problems

any suggestions, and please can any correct thos misc in the wiki
respect the string manipulation fuctions!?
Lenz McKAY Gerardo (PICCORO)
http://qgqlochekone.blogspot.com


2015-12-14 17:54 GMT-04:30 Tobias Boege <taboege at ...626...>:
> On Mon, 14 Dec 2015, willy at ...3474... wrote:
>> On 2015-12-14 23:01, PICCORO McKAY Lenz wrote:
>> > i think the problem are again in documentation or some misc-information
>> >
>> > search at documentation seem that the difference are the manipulation
>> > respect set of
>> >
>> > one its for ACII charset and the other seem are for UTF-8
>> >
>> > BUT DOCUMENTATIION refers without linking.. i link with a "see also"
>> > and "advertise"
>> >
>> > if i are correct please benoit guide me!
>> >
>
> Please take extra care to not make the docs by any chance worse with your
> English, and don't write something which you are not sure about.
>
>> You seem to be correct:
>>
>> Left$() -> This function only deal with ASCII strings. To manipulate
>> UTF-8 strings, use the Left class.
>> Left() -> This function deals with UTF-8 strings, and so all positions
>> and lengths are given in characters and not in bytes. For deal with
>> ASCII see Left$
>>
>> Documentation is clear on that, I wasn't even aware of the
>> difference...!!
>>
>> So, I guess the question of removal is no longer an issue as they are
>> two different functions :)
>>
>
> No, there are these two kinds of string manipulation functions:
>
>  1. The intrinsic functions which come in pairs: Left$(), Left(), Mid$(),
>     Mid(), etc. which are built into the language, and
>  2. The methods of the String class in the gb component.
>
> Modulo naming, the functions of the first kind are identical -- which was
> the original question I think. Only in the mail quoted above PICCORO mixed
> the second kind in.
>
> Regards,
> Tobi
>
> --
> "There's an old saying: Don't change anything... ever!" -- Mr. Monk
>
> ------------------------------------------------------------------------------
> _______________________________________________
> Gambas-user mailing list
> Gambas-user at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gambas-user




More information about the User mailing list