blob: 7a0029b234ba51a8cddbb76323efdd4dbc95a324 (
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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
// { dg-do assemble }
// Test for PRETTY_FUNCTION
class SV;
class SVTable // : public Debug
{
// It is an array to pointer to a SV.
SV ** array;
// This is the size of array.
int maxCount;
// This is the current element count.
int count;
void fatal_error (const char *f, ...);
public:
SVTable (int size, const char *d);
SVTable ();
SVTable (const SVTable &);
~SVTable () {}
};
SVTable::SVTable (int size, const char *d)
: maxCount (size), count (0)// , Debug (d)
{
if (size < 0)
{
fatal_error ("%s: Invalid size: %d\n", __PRETTY_FUNCTION__, size);
}
array = (SV **) new SV * [size];
if (array == 0)
{
fatal_error ("%s: Failed to allocate array\n", __PRETTY_FUNCTION__);
}
}
|