10 public static void main () {
11 SimpleStruct
* st
= new SimpleStruct
[1];
13 assert (st
->field
== st
->test ());
16 test_pointers_element_access ();
17 test_pointers_return_value ();
20 static void test_pointers_element_access () {
21 int* array
= new
int[42];
23 assert (array
[0] == 23);
27 const int[] array
= { 42 };
29 static int* return_pointer () {
33 static void test_pointers_return_value () {
34 int i
= return_pointer ()[0];