Mercurial > projects > ldc
annotate tests/mini/slices2.d @ 1135:8ebbad15fc99
Remove struct padding which was making this test fail on 64-bit systems.
author | Frits van Bommel <fvbommel wxs.nl> |
---|---|
date | Tue, 24 Mar 2009 03:14:22 +0100 |
parents | bb4a81e68ddb |
children |
rev | line source |
---|---|
820
bb4a81e68ddb
Implemented allocating storage for a slice if its address is taken, fixes #115
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff
changeset
|
1 void main() |
bb4a81e68ddb
Implemented allocating storage for a slice if its address is taken, fixes #115
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff
changeset
|
2 { |
bb4a81e68ddb
Implemented allocating storage for a slice if its address is taken, fixes #115
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff
changeset
|
3 int[10] arr = void; |
bb4a81e68ddb
Implemented allocating storage for a slice if its address is taken, fixes #115
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff
changeset
|
4 int[]* ptr = &arr[1..3]; |
bb4a81e68ddb
Implemented allocating storage for a slice if its address is taken, fixes #115
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff
changeset
|
5 } |