root/lang/d/portingdemo/main.d @ 7240

Revision 7240, 0.5 kB (checked in by itkz, 5 years ago)

faild on 32bit OS, maybe success on 64bit OS...?

Line 
1
2
3import std.string;
4
5import unko;
6
7
8int main(char[][] args)
9{
10        unko_t* unko;
11        unko = create_unko();
12
13        printf(
14                "%d:%d:%d\n",
15                unko_t.first.offsetof, get_offsetof_first(), *unko.first);
16        printf(
17                "%d:%d:%d\n",
18                unko_t.second.offsetof, get_offsetof_second(), unko.second);
19        printf(
20                "%d:%d:%d\n",
21                unko_t.third.offsetof, get_offsetof_third(), unko.third);
22        printf(
23                "%d:%d:%d\n",
24                unko_t.fourth.offsetof, get_offsetof_fourth(), *unko.fourth);
25
26        scope(exit) {
27                delete_unko(unko);
28        }
29
30        return 0;
31}
Note: See TracBrowser for help on using the browser.