diff options
author | alaviss <alaviss@users.noreply.github.com> | 2020-01-20 09:51:21 +0000 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2020-01-20 10:51:21 +0100 |
commit | 470faa97c60aa5d8153f00083913aca4f0dc1fdf (patch) | |
tree | 6512d3029c96fa0fb28b86f3f3393ab15ecbdd37 /compiler | |
parent | da1bddb084443f7f386a04c853eb5c1c03b28ce4 (diff) | |
download | Nim-470faa97c60aa5d8153f00083913aca4f0dc1fdf.tar.gz |
compiler/ccgtypes: hide exportc proc unless it has dynlib (#13199)
This hides most of stdlib's internal functions from resulting binaries/libraries, where they aren't needed on *nix. Static libraries are not affected by this change (visibility doesn't apply to them).
Diffstat (limited to 'compiler')
-rw-r--r-- | compiler/ccgtypes.nim | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/ccgtypes.nim b/compiler/ccgtypes.nim index 905f8999e..59f47b02d 100644 --- a/compiler/ccgtypes.nim +++ b/compiler/ccgtypes.nim @@ -954,7 +954,7 @@ proc genProcHeader(m: BModule, prc: PSym, asPtr: bool = false): Rope = result.add "N_LIB_EXPORT " elif prc.typ.callConv == ccInline or asPtr or isNonReloadable(m, prc): result.add "static " - elif {sfImportc, sfExportc} * prc.flags == {}: + elif sfImportc notin prc.flags: result.add "N_LIB_PRIVATE " var check = initIntSet() fillLoc(prc.loc, locProc, prc.ast[namePos], mangleName(m, prc), OnUnknown) |