From fcdcf1b1e9fb07bf9e8012e80d79ad6a540b53a6 Mon Sep 17 00:00:00 2001 From: Saleem Abdulrasool Date: Wed, 3 Jun 2015 17:25:33 +0000 Subject: [PATCH] fallback_malloc: silence qual-cast warning (NFC) This silences a GCC 4.9.2 qual-cast warning in the fallback_malloc codepath. NFC. llvm-svn: 238944 --- libcxxabi/src/fallback_malloc.ipp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libcxxabi/src/fallback_malloc.ipp b/libcxxabi/src/fallback_malloc.ipp index 135d4891a6ba..56da36c17ffa 100644 --- a/libcxxabi/src/fallback_malloc.ipp +++ b/libcxxabi/src/fallback_malloc.ipp @@ -68,7 +68,7 @@ heap_node *node_from_offset ( const heap_offset offset ) { return (heap_node *) ( heap + ( offset * sizeof (heap_node))); } heap_offset offset_from_node ( const heap_node *ptr ) - { return static_cast(static_cast(((char *) ptr ) - heap) / sizeof (heap_node)); } + { return static_cast(static_cast(reinterpret_cast(ptr) - heap) / sizeof (heap_node)); } void init_heap () { freelist = (heap_node *) heap;