Skip to content

Commit

Permalink
Bug 1256530 - Fix compiler warnings about casting to larger size. r=h…
Browse files Browse the repository at this point in the history
…sivonen

Specifically, the Microsoft VS2015u1 compiler said:
warning C4312: 'type cast': conversion from 'unsigned int' to
'nsIContent *' of greater size
  • Loading branch information
Mats Palmgren committed Mar 17, 2016
1 parent 98faf09 commit 1492cdc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion parser/html/nsHtml5Highlighter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -648,7 +648,7 @@ nsHtml5Highlighter::AllocateContentHandle()
mHandlesUsed = 0;
}
#ifdef DEBUG
mHandles[mHandlesUsed] = (nsIContent*)0xC0DEDBAD;
mHandles[mHandlesUsed] = reinterpret_cast<nsIContent*>(uintptr_t(0xC0DEDBAD));
#endif
return &mHandles[mHandlesUsed++];
}
Expand Down
2 changes: 1 addition & 1 deletion parser/html/nsHtml5TreeBuilderCppSupplement.h
Original file line number Diff line number Diff line change
Expand Up @@ -1003,7 +1003,7 @@ nsHtml5TreeBuilder::AllocateContentHandle()
mHandlesUsed = 0;
}
#ifdef DEBUG
mHandles[mHandlesUsed] = (nsIContent*)0xC0DEDBAD;
mHandles[mHandlesUsed] = reinterpret_cast<nsIContent*>(uintptr_t(0xC0DEDBAD));
#endif
return &mHandles[mHandlesUsed++];
}
Expand Down

0 comments on commit 1492cdc

Please sign in to comment.