hi, all I can think of is to do y='\002';
... its really a pitty that there is no such thing as 'tiny int'. Stefan [EMAIL PROTECTED] wrote: > Some sort of compatibility rules should be useful for integer constants > v.s. other predefined types. > This is particularly true for the "char" predefined type. > For other types the following suffix could be used (but not for legacy > code): > unsigned-suffix: one of u U > long-suffix: one of l L > long-long-suffix: one of ll LL > > For instance, in: > int x; > char y; > y=x; /* flag this */ > x=1; /* don't flag this */ > y=2; /* don't flag this */ > > Anyway I get: > Assignment of int to char: y=2 > To make char and int types equivalent, use +charint > > But I don't want to use +charint, otherwise I would loose the warning for y=x; > > Could anyone help me please ? > Marco Giromini > > ---------------------- Forwarded by Marco Giromini/MAIN/MC1 on 09/26/2003 > 12:04 PM --------------------------- > > Derek M Jones <[EMAIL PROTECTED]>@cs.virginia.edu on 08/21/2003 08:50:42 > PM > > Please respond to [EMAIL PROTECTED] > > Sent by: [EMAIL PROTECTED] > > > To: [EMAIL PROTECTED] > cc: > > Subject: Re: [splint-discuss] Very strict cast checking > > ... > > However, simply treating typedef names as distinct types is too > simplistic. Some sort of compatibility rules have to be worked out for > integer constants. For instance, in: > > typedef int MY_INT; > int x; > MY_INT y; > > x+y; /* flag this */ > x+1; /* don't flag this */ > y+1; /* don't flag this */ > > > > _______________________________________________ > splint-discuss mailing list > [EMAIL PROTECTED] > http://www.splint.org/mailman/listinfo/splint-discuss > -- \|/ Stefan Kost <@ @> private business +-oOO-(_)-OOo------------------------------------------------------ - - - - - | __ Address Simildenstr. 5 HTWK Leipzig, Fb IMN, Postfach 301166 | /// 04277 Leipzig 04277 Leipzig | __ /// Germany Germany | \\\/// Phone +49341 2253538 +49341 30766101 | \__/ EMail st_kost_at_gmx.net kost_at_imn.htwk-leipzig.de | WWW www.sonicpulse.de www.imn.htwk-leipzig.de/~kost/about.html ===-=-=--=---=---------------------------------- - - - - - _______________________________________________ splint-discuss mailing list [EMAIL PROTECTED] http://www.splint.org/mailman/listinfo/splint-discuss