有谁见过main这种用法
void main(argc,argv) int argc; char **argv{...}; 有谁见过main这种用法,到到底是代码写错了还是就有这种用法,因为完整的代码无法通过编译,所以也不知道这种用法行得通不。
void main(argc, argv)
int argc;
char **argv;
{
Window win;
unsigned int width, height; /* Window size */
int x, y; /* Window position */
unsigned int border_width = 4; /* Four pixels */
unsigned int display_width, display_height;
unsigned int icon_width, icon_height;
char *window_name = "Basic Window Program";
char *icon_name = "basicwin";
Pixmap icon_pixmap;
XSizeHints *size_hints;
XIconSize *size_list;
XWMHints *wm_hints;
XClassHint *class_hints;
XTextProperty windowName, iconName;
int count;
XEvent report;
GC gc;
XFontStruct *font_info;
char *display_name = NULL;
int window_size = 0; /* BIG_ENOUGH or TOO_SMALL to
* display contents */
progname = argv[0];
if (!(size_hints = XAllocSizeHints())) {
fprintf(stderr, "%s: failure allocating memory, progname);
exit(0);
}
int argc;
char **argv;
{
Window win;
unsigned int width, height; /* Window size */
int x, y; /* Window position */
unsigned int border_width = 4; /* Four pixels */
unsigned int display_width, display_height;
unsigned int icon_width, icon_height;
char *window_name = "Basic Window Program";
char *icon_name = "basicwin";
Pixmap icon_pixmap;
XSizeHints *size_hints;
XIconSize *size_list;
XWMHints *wm_hints;
XClassHint *class_hints;
XTextProperty windowName, iconName;
int count;
XEvent report;
GC gc;
XFontStruct *font_info;
char *display_name = NULL;
int window_size = 0; /* BIG_ENOUGH or TOO_SMALL to
* display contents */
progname = argv[0];
if (!(size_hints = XAllocSizeHints())) {
fprintf(stderr, "%s: failure allocating memory, progname);
exit(0);
}