aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/g++.old-deja/g++.other/sc1.C
blob: 054a57a6cda6b28966d09cadccc2a5cfa7bd1b03 (plain)
1
2
3
4
5
6
7
8
9
10
// { dg-do assemble  }
// Origin: Mark Mitchell <mark@codesourcery.com>

void f() {
  int *i = 0;
  const int *c = 0;

  static_cast <const int *>(i);
  static_cast <int *>(c);  // { dg-error "" } casts away constness
}