Suppress warning: removing "void *" - undefined
2 answers
Better to change your code to avoid this warning rather than suppress it! If handled incorrectly, it can lead to surprises that are much more difficult to find.
[Note. To answer your question, which should be taken with a grain of salt, you can use free()
instead delete
as it converts any pointer to void*
before freeing it. Make sure the destructors are called correctly before doing this.]
+3
source to share