Exported functions should be public by default #2989
Labels
proposal
This issue suggests modifications. If it also has the "accepted" label then it is planned.
Milestone
The windows subsystem detection did not properly work, because the exported
WinMain
function was not defined with thepub
keyword. This caused the@hasDecl
builtin to not find theWinMain
function and caused the subsystem detection to be wrong. The following example is relevant:Without the
pub
in front ofexport fn WinMain(...
this showed that the subsystem was.Console
, whereas with thepub
it correctly showed.Windows
.Solution
pub
keyword.@hasDecl
to also return true for exported functions.I would like to implement the fix for this, once I know which solution is the best.
The text was updated successfully, but these errors were encountered: