Tokenizer: Added a comment about sizeof for struct/class. We always assume that the size is 100

This commit is contained in:
Daniel Marjamäki 2011-02-06 09:58:07 +01:00
parent 2214de7bbc
commit f7dcf2d3b9
1 changed files with 2 additions and 0 deletions

View File

@ -3808,6 +3808,8 @@ void Tokenizer::simplifySizeof()
{ {
if (Token::Match(tok, "class|struct %var%")) if (Token::Match(tok, "class|struct %var%"))
{ {
// we assume that the size of structs and classes are always
// 100 bytes.
_typeSize[tok->strAt(1)] = 100; _typeSize[tok->strAt(1)] = 100;
} }
} }