Summary: | KDevelop treats signed and unsigned chars as ints when used as template parameters | ||
---|---|---|---|
Product: | [Applications] kdevelop | Reporter: | Alexander Shaduri <ashaduri> |
Component: | Language Support: CPP (old) | Assignee: | kdevelop-bugs-null |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | cponnapalli |
Priority: | NOR | ||
Version First Reported In: | git master | ||
Target Milestone: | --- | ||
Platform: | Compiled Sources | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | 5.0.0 | |
Sentry Crash Report: | |||
Attachments: |
unsigned char when used as template
Signed char used as template |
Description
Alexander Shaduri
2011-07-25 16:43:25 UTC
Created attachment 98737 [details]
unsigned char when used as template
Reproduced the above steps:
1. Executed the code given.
2. Kdevelop does not treat the signed char type as signed int.
3. Similarly, unsigned char is not treated as unsigned int.
4. Attached the screen shots containing the code executed.
In accordance to the statement in expected result:
A char is both a character representation, but for the purposes of converting to an int, it's also a int representation. A simple char is used to store simple characters. However, if you are using character types as numbers then use signed char(-127 t0 +127 range) and unsigned char(0 t0 255.)
Created attachment 98738 [details]
Signed char used as template
Fixed in KDevelop 5, indeed. |