W
William Payne
In the following code, should the code compile without casting &n to void* ?
My compiler accepts it, but should it?
void foo(void*)
{
}
struct bar
{
int n;
};
int main()
{
bar inst;
foo(&inst); /* Does standard C++ require a void* cast here? */
}
/ William Payne
My compiler accepts it, but should it?
void foo(void*)
{
}
struct bar
{
int n;
};
int main()
{
bar inst;
foo(&inst); /* Does standard C++ require a void* cast here? */
}
/ William Payne