2008-01-03から1日間の記事一覧

PODと集成体の静的初期化

C++

http://d.hatena.ne.jp/y-hamigaki/comment?date=20080102#c 話が二転三転してますが、 struct hoge { int n; }; void func() { static int a = 1; // 静的初期化とは限らない static hoge b = { 2 }; // 静的初期化? } このaとbの初期化タイミングが違うっ…