Re: [AD] Proposed END_OF_MAIN documentation. |
[ Thread Index |
Date Index
| More lists.liballeg.org/allegro-developers Archives
]
> +@@Macro @END_OF_MAIN();
> +@xref Windows specifics, Unix specifics, Differences between platforms
> +@xref exhello
> + In order to maintain cross-platform compatibility, you have to put
> this + macro at the very end of your main function. This macro uses some
> `magic' + to mangle your main procedure under platforms
... on platforms...
> which need it like Windows
> + or Linux. In the other platforms this macro compiles to
On the other platforms...
> nothing, so you + don't have to #ifdef it around. Example:
> +<codeblock>
> + int main(void)
> + {
> + allegro_init();
> + /* here some more stuff */
> + ...
> + return 0;
> + }
> + END_OF_MAIN();
> +<endblock>
No semi-colon after END_OF_MAIN().
Ok with these changes. Can you put it on the 4.0 branch or do you want me to
do it for you?
--
Eric Botcazou