binaryninja-api
binaryninja-api copied to clipboard
If the type being switched on is 'char'/'wchar' then the switch cases should be shown as char constants
Consider the following switch statement:

In this case since the type being switched on is char we should be able to display the case labels as char as well.
This can be handled in the very same was as we handle enum values
Propagating the type to the case expression constants is easy enough like @xusheng6 said however the char type is in fact, not a type, but the textual representation of int8_t. We can either:
- Just do this and be ok with non-char
int8_ttypes having their display type changed to a constant character display type. - Make a separate char type.
Blocking on: #5355