aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/g++.old-deja/g++.ext/memconst.C
blob: 7e861563cce91f5ea34a5348c9e8983aff2b9c69 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
// { dg-do assemble  }
// { dg-options "-pedantic -pedantic-errors" }
// From: Ove.Ewerlid@syscon.uu.se (Ove Ewerlid)
// Subject: ss-940630:cc1plus: internal error
// Date: Sat, 2 Jul 1994 05:07:20 +0200

class qwerty {
public:
    qwerty (const unsigned short userkey[8]);
   ~qwerty ();
};

class foo {
private:
  static const unsigned char * const dummy_key = (unsigned char*)"ThisIs a dummy!"; // { dg-error "" } 

public:
    void bar ();
};

void
foo::bar ()
{
    qwerty QWERTY ((unsigned short*)dummy_key);
}