{"comment":{"url":"https://api.github.com/repos/D-Programming-GDC/GDC/comments/10577172","html_url":"https://github.com/D-Programming-GDC/GDC/commit/b20184d7639a8e5529cd6172e094d5d2affbb496#commitcomment-10577172","id":10577172,"user":{"login":"jens-gpio","id":5781101,"avatar_url":"https://avatars.githubusercontent.com/u/5781101?v=3","gravatar_id":"","url":"https://api.github.com/users/jens-gpio","html_url":"https://github.com/jens-gpio","followers_url":"https://api.github.com/users/jens-gpio/followers","following_url":"https://api.github.com/users/jens-gpio/following{/other_user}","gists_url":"https://api.github.com/users/jens-gpio/gists{/gist_id}","starred_url":"https://api.github.com/users/jens-gpio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jens-gpio/subscriptions","organizations_url":"https://api.github.com/users/jens-gpio/orgs","repos_url":"https://api.github.com/users/jens-gpio/repos","events_url":"https://api.github.com/users/jens-gpio/events{/privacy}","received_events_url":"https://api.github.com/users/jens-gpio/received_events","type":"User","site_admin":false},"position":null,"line":null,"path":"","commit_id":"b20184d7639a8e5529cd6172e094d5d2affbb496","created_at":"2015-04-05T13:08:14Z","updated_at":"2015-04-05T13:08:14Z","body":"I've tested this, and it works very well for me and demonstrates how convenient D is!\r\n\r\nA small working example:\r\n\r\nimport gcc.attribute;\r\n\r\nalias extern(C) immutable void function() VectorFunc;\r\n@attribute(\"section\",\".isr_vector\") VectorFunc [100] g_pfnVectors = [\r\n\tcast(VectorFunc) 0x10001000,\t// initial stack pointer\r\n\t&Reset_Handler,\t\t\t\t\t// reset handler\r\n\tcast(VectorFunc)0xfeedface\t\t// a junk-value\r\n\t];\r\n\r\nextern(C) void Reset_Handler()\r\n{\r\n\twhile(true){}\r\n}\r\n"}}