什么是“主要”功能不同的有效原型? [英] What are the different valid prototypes of 'main' function?

查看:110
本文介绍了什么是“主要”功能不同的有效原型?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

可能重复:结果
  <一href=\"http://stackoverflow.com/questions/2108192/what-are-the-valid-signatures-for-cs-main-function\">What是对C的main()函数的有效签名?

什么是'主'功能不同的有效原型?

What are the different valid prototypes of 'main' function?

是否有一些不规范的原型也只有少数厂商的支持?

Are there some non-standard prototypes also supported only by a few vendors?

推荐答案

C标准(宗; 5.1.2.2.1)定义了两个入口点的原型:

The C standard (§ 5.1.2.2.1) defines two entry point prototypes:

int main(void);

int main(int argc, char **argv);

除此之外,每个OS具有其自己的附加非标准入口点。 WinMain函数等。

Other than that, every OS has its own additional non-standard entry points. WinMain, etc.

这篇关于什么是“主要”功能不同的有效原型?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆