-
-
Notifications
You must be signed in to change notification settings - Fork 264
explicit casting for const #610
Copy link
Copy link
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
#include <iostream>
#include <limits.h>
int main (int argc, char *argv[]) {
const int a = 10;
int *p = (int *)&a;
return 0;
}give
#include <iostream>
#include <limits.h>
int main(int argc, char ** argv)
{
const int a = 10;
int * p = static_cast<int *>(&a);
return 0;
}Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working