texmacs-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Texmacs-dev] [RFC] no character in font information


From: Igor V. Kovalenko
Subject: Re: [Texmacs-dev] [RFC] no character in font information
Date: Tue, 05 Nov 2002 18:39:48 +0300
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.0.1) Gecko/20020809

Joris van der Hoeven wrote:
Inspired by valgrind debugging I added a simple check to
tex_font_metric_rep::tag function:

int tex_font_metric_rep::tag (QN c)
{
    ...
    if (c < bc) {
    ...
    if (c > ec) {
    ...
    return (char_info [c-bc]>>8)&3;
}

A test run give lines in output:

tex_font_metric_rep::tag  c=254 > ec=127 (res_name=cmr8)
tex_font_metric_rep::tag  c=254 > ec=127 (res_name=cmr12)


Yes, this is indeed a subtle bug.
I corrected it for the next version.

While relooking at the code, I also noticed something else:
the tfm files are read in 32 bit blocks using the "int" type.
I am not sure that this is correct on 64 bits architectures.
Are there 64 bits architectures where the "int" type is 64 bits?
In that case, maybe someone is willing to patch this.


Well, compiler's representation for int type is to be choosen
as to match machine word size. So on 64-bit arch size of int is 64 bit,
if compiler is really a 64-bit one.

--
Regards,
Igor V. Kovalenko    mailto: iko at crec dot mipt dot ru





reply via email to

[Prev in Thread] Current Thread [Next in Thread]