@@ -2954,8 +2954,8 @@ $(H3 $(LNAME2 anonymous, Anonymous Functions and Anonymous Delegates))
2954
2954
$(H2 $(LNAME2 main, $(D main()) Function))
2955
2955
2956
2956
$(P For console programs, $(D main()) serves as the entry point.
2957
- It gets called after all the module initializers are run, and
2958
- after any unittests are run.
2957
+ It gets called after all the $(DDSUBLINK spec/ module, staticorder, module initializers)
2958
+ are run, and after any $(DDLINK spec/unittest, Unit Tests, unittests) are run.
2959
2959
After it returns, all the module destructors are run.
2960
2960
$(D main()) must be declared as follows:
2961
2961
)
@@ -2974,16 +2974,16 @@ $(H2 $(LNAME2 main, $(D main()) Function))
2974
2974
2975
2975
$(UL
2976
2976
$(LI If `main` returns `void`, the OS will receive a zero value on success.)
2977
- $(LI If `main` returns `void` or `noreturn`, the OS will receive a non-zero
2977
+ $(LI If `main` returns `void` or `noreturn`, the OS will receive a non-zero
2978
2978
value on abnormal termination, such as an uncaught exception.)
2979
2979
$(LI If `main` is declared as `auto`, the inferred return type must be
2980
2980
one of `void`, `int` and `noreturn`.)
2981
2981
)
2982
-
2982
+
2983
2983
$(P If the $(D string[]) parameter is declared, the parameter will hold any
2984
2984
arguments passed to the program by the OS. The first argument is typically
2985
2985
the executable name, followed by any command-line arguments.)
2986
-
2986
+
2987
2987
$(P The main function must have D linkage.)
2988
2988
2989
2989
$(P Attributes may be added as needed, e.g. `@safe`, `@nogc`, `nothrow`, etc.)
0 commit comments