llvm2c icon indicating copy to clipboard operation
llvm2c copied to clipboard

Set the signess of a variable in declaration if it is always used with a sign.

Open mchalupa opened this issue 6 years ago • 1 comments

If a variable is cast to e.g. int everywhere in the program, we may declare it int instead of unsigned int (and the casts visitor then removes useless casts). The question is whether we can easily track the casts of the variable.

mchalupa avatar Sep 03 '19 10:09 mchalupa

Currently, it's not possible to easily distinguish whether a Value is a variable or a constant. It'd be wise to work on that before fixing this.

tomsik68 avatar Sep 08 '19 20:09 tomsik68