From 82f87e63e83dc4311bb66d3866574b212059edc9 Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Sun, 16 Nov 2003 20:21:15 +0000 Subject: Fixes for PR114: Thanks to Reid Spencer! llvm-svn: 10029 --- llvm/include/Support/HashExtras.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'llvm/include/Support/HashExtras.h') diff --git a/llvm/include/Support/HashExtras.h b/llvm/include/Support/HashExtras.h index 871080c4675..67f65b5f3ac 100644 --- a/llvm/include/Support/HashExtras.h +++ b/llvm/include/Support/HashExtras.h @@ -31,7 +31,9 @@ template <> struct hash { // Provide a hash function for arbitrary pointers... template struct hash { - inline size_t operator()(const T *Val) const { return (size_t)Val; } + inline size_t operator()(const T *Val) const { + return reinterpret_cast(Val); + } }; } // End namespace std -- cgit v1.2.3