You should be able to do

type T;
unsigned T x;

or perhaps even just

unsigned x;

However, the success of this depends on the software you are working on.  
Linux code has a huge number of typedefs for various unsigned types.

julia

On Fri, 22 Aug 2014, Peter Senna Tschudin wrote:

> Gmail has changed the text format. There is a tab before
> cocci.include_match(False)
> 
> On Fri, Aug 22, 2014 at 11:28 PM, Peter Senna Tschudin
> <[email protected]> wrote:
> > I would try:
> > @r@
> > type T;
> > identifier i;
> > @@
> > T i;
> >
> > @script:python@
> > T << r.T;
> > @@
> > if "unsigned" not in T:
> > cocci.include_match(False)
> >
> > @printer@
> > type r.T;
> > identifier r.i;
> > @@
> > * T i;
> >
> > On Fri, Aug 22, 2014 at 10:38 PM, Mitchell Cuddie <[email protected]> wrote:
> >> Julia,
> >>
> >> I would like to declare a metatype T, where T is restricted to the set
> >> of unsigned types.
> >>
> >> (i.e. unsigned long, unsigned int, but not int or long)
> >>
> >> cheers,
> >>
> >> Mitchell
> >> _______________________________________________
> >> Cocci mailing list
> >> [email protected]
> >> https://systeme.lip6.fr/mailman/listinfo/cocci
> >
> >
> >
> > --
> > Peter
> 
> 
> 
> -- 
> Peter
> _______________________________________________
> Cocci mailing list
> [email protected]
> https://systeme.lip6.fr/mailman/listinfo/cocci
> 
_______________________________________________
Cocci mailing list
[email protected]
https://systeme.lip6.fr/mailman/listinfo/cocci

Reply via email to