Cppcheck has problems with this code and I have the feeling that we do not simplify it properly:
#include <utility> typedef unsigned char a4[4]; int main () { a4 a4obj; a4 && a4_rref = std::move(a4obj); a4* a4p = &(a4obj); a4*&& a4p_rref = std::move(a4p); return 0; }
What is the corresponding code without using a typedef?
This compiles for me:
#include <utility> int main() { unsigned char a4obj[4]; unsigned char (&&a4_rref)[4] = std ::move(a4obj); unsigned char(*a4p)[4]; a4p = &(a4obj); unsigned char (*&&a4p_rref)[4] = std ::move(a4p); return 0; }
It also doesn't crash in cppcheck either.
Thanks! I'll try to output that in Tokenizer::simplifyTypedef.
Tokenizer::simplifyTypedef
Log in to post a comment.
Cppcheck has problems with this code and I have the feeling that we do not simplify it properly:
What is the corresponding code without using a typedef?
This compiles for me:
It also doesn't crash in cppcheck either.
Thanks! I'll try to output that in
Tokenizer::simplifyTypedef
.