[Fribidi-discuss] type of fribidi_iso8859_8_to_unicode changed in CVS

Tzafrir Cohen tzafrir at technion.ac.il
Mon Dec 31 16:15:02 EST 2001


On Tue, 1 Jan 2002, Behdad Esfahbod wrote:

>
> Tzafrir, do you think does it suffice that I define the old style as
> macros? like this:
>
> #define fribidi_iso8859-8_to_unicode(s, us) \
> 	fribidix_iso8859-8_to_unicode(s, strlen(s), us)
>
> it has the problem with evaluating s twice.

For what I need, it will suffice.

>
> On Tue, 1 Jan 2002, Behdad Esfahbod wrote:
>
> > You're right, I'm fixing it right now, check the same url in an hour.
> >
> >
> > On Tue, 1 Jan 2002, Tzafrir Cohen wrote:
> >
> > > On Tue, 1 Jan 2002, Behdad Esfahbod wrote:
> > >
> > > > Hi,
> > > >
> > > > As you may know, we didn't assume that FriBidiChar* strings has been
> > > > terminated with a U+0000, and ask for length in all functions, then I
> > > > found it better to do the same assumption on char* strings, its a bit
> > > > weird, but makes things more clean, as all the fribidi_*_to_unicode
> > > > functions used to have a line 'int len = strlen(s);', then I decided
> > > > to ask for len in input, It has the advantage that you can pass a part
> > > > of string to converter, I used to terminate my strings in middle, and
> > > > then restore the poor charater back and continue....
> > > >
> > > > As we are still below release 1.x.y, I let myself to change the
> > > > interface a little, also added a FRIBIDI_INTERFACE_VERSION macro,
> > > > which will be increased with each interface change.
> > > >
> > > > If you cannot pass a strlen(s) yourself, I can define some macros to
> > > > do this for you, or maybe you're right, I should rename the new
> > > > interface, define the old ones as before, let me know.
> > > >
> > >
> > > I know the length at that point. My only problem is writing a code that
> > > will work with both versions. I suppose I can write there a macro that
> > > will ignore ", length" for versions older than 0.10.0 in that call. But it
> > > looks ugly...
> > >
> > > >
> > > > Also I encourage you to use
> > > > 'fribidi_charset_to_unicode(FRIBIDI_CHARSET_ISO8859_8, ...) instead.
> > > >
> > > > behdad
> > > >
> > > > On Tue, 1 Jan 2002, Tzafrir Cohen wrote:
> > > >
> > > > > Hi
> > > > >
> > > > > I noticed that fribidi_iso8859_8_to_unicode of 0.10pre has a "length"
> > > > > parameter, unlike all previous versions (up to 0.9.1).
> > > > >
> > > > > Why is that?
> > > > >
> > > > > (It breaks my program)
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>
>

-- 
Tzafrir Cohen
mailto:tzafrir at technion.ac.il
http://www.technion.ac.il/~tzafrir






More information about the FriBidi mailing list