add some more windows types
This commit is contained in:
parent
fe3d6bf8ea
commit
6f3807d915
|
@ -5301,7 +5301,7 @@ void Tokenizer::simplifyPlatformTypes()
|
||||||
tok->insertToken("char");
|
tok->insertToken("char");
|
||||||
} else if (tok->str() == "CHAR")
|
} else if (tok->str() == "CHAR")
|
||||||
tok->str("char");
|
tok->str("char");
|
||||||
else if (Token::Match(tok, "DWORD|ULONG")) {
|
else if (Token::Match(tok, "DWORD|ULONG|COLORREF")) {
|
||||||
tok->str("unsigned");
|
tok->str("unsigned");
|
||||||
tok->insertToken("long");
|
tok->insertToken("long");
|
||||||
} else if (Token::Match(tok, "DWORD_PTR|ULONG_PTR|SIZE_T")) {
|
} else if (Token::Match(tok, "DWORD_PTR|ULONG_PTR|SIZE_T")) {
|
||||||
|
@ -5318,7 +5318,7 @@ void Tokenizer::simplifyPlatformTypes()
|
||||||
tok->insertToken("long");
|
tok->insertToken("long");
|
||||||
} else if (tok->str() == "LONG")
|
} else if (tok->str() == "LONG")
|
||||||
tok->str("long");
|
tok->str("long");
|
||||||
else if (tok->str() == "LONG_PTR") {
|
else if (Token::Match(tok, "LONG_PTR|LPARAM|LRESULT")) {
|
||||||
tok->str("long");
|
tok->str("long");
|
||||||
if (_settings->platformType == Settings::Win64)
|
if (_settings->platformType == Settings::Win64)
|
||||||
tok->insertToken("long");
|
tok->insertToken("long");
|
||||||
|
@ -5350,26 +5350,28 @@ void Tokenizer::simplifyPlatformTypes()
|
||||||
} else if (Token::Match(tok, "LPSTR|PSTR|PCHAR")) {
|
} else if (Token::Match(tok, "LPSTR|PSTR|PCHAR")) {
|
||||||
tok->str("char");
|
tok->str("char");
|
||||||
tok->insertToken("*");
|
tok->insertToken("*");
|
||||||
} else if (Token::Match(tok, "LPVOID|PVOID|HANDLE")) {
|
} else if (Token::Match(tok, "LPVOID|PVOID|HANDLE|HBITMAP|HBRUSH|HCOLORSPACE|HCURSOR|HDC|HFONT|HGDIOBJ|HGLOBAL|HICON|HINSTANCE|HKEY|HLOCAL|HMENU|HMETAFILE|HMODULE|HPALETTE|HPEN|HRGN|HRSRC|HWND")) {
|
||||||
tok->str("void");
|
tok->str("void");
|
||||||
tok->insertToken("*");
|
tok->insertToken("*");
|
||||||
|
} else if ((tok->str() == "PHANDLE")) {
|
||||||
|
tok->str("void");
|
||||||
|
tok->insertToken("*");
|
||||||
|
tok->insertToken("*");
|
||||||
} else if (Token::Match(tok, "LPWORD|PWORD")) {
|
} else if (Token::Match(tok, "LPWORD|PWORD")) {
|
||||||
tok->str("unsigned");
|
tok->str("unsigned");
|
||||||
tok->insertToken("*");
|
tok->insertToken("*");
|
||||||
tok->insertToken("short");
|
tok->insertToken("short");
|
||||||
} else if (tok->str() == "SHORT")
|
} else if (tok->str() == "SHORT")
|
||||||
tok->str("short");
|
tok->str("short");
|
||||||
else if (tok->str() == "UINT") {
|
else if (Token::Match(tok, "UINT|MMRESULT|SOCKET")) {
|
||||||
tok->str("unsigned");
|
tok->str("unsigned");
|
||||||
tok->insertToken("int");
|
tok->insertToken("int");
|
||||||
} else if (tok->str() == "UINT_PTR") {
|
} else if (Token::Match(tok, "UINT_PTR|WPARAM")) {
|
||||||
tok->str("unsigned");
|
tok->str("unsigned");
|
||||||
if (_settings->platformType == Settings::Win64) {
|
|
||||||
tok->insertToken("long");
|
tok->insertToken("long");
|
||||||
|
if (_settings->platformType == Settings::Win64)
|
||||||
tok->insertToken("long");
|
tok->insertToken("long");
|
||||||
} else
|
} else if (Token::Match(tok, "USHORT|WORD|WCHAR|ATOM|wchar_t")) {
|
||||||
tok->insertToken("long");
|
|
||||||
} else if (Token::Match(tok, "USHORT|WORD|WCHAR|wchar_t")) {
|
|
||||||
tok->str("unsigned");
|
tok->str("unsigned");
|
||||||
tok->insertToken("short");
|
tok->insertToken("short");
|
||||||
} else if (tok->str() == "VOID")
|
} else if (tok->str() == "VOID")
|
||||||
|
|
Loading…
Reference in New Issue