Skip to content

AST-1233 Hide all symbols except those that should be visible

Maik Nijhuis requested to merge ast-1233-hide-internal-symbols into master

Hiding all symbols prevents issues such as the following:

  • EveryBeam uses aocommon. Because all symbols are visible, EveryBeam exposes the aocommon::FitsReader::initialize function.
  • WSClean uses both EveryBeam and aocommon and therefore also defines the aocommon::FitsReader::initialize function.
  • When EveryBeam calls aocommon::FitsReader::initialize, it calls the function defined in WSClean, since that's the first occurrence of the function when WSClean is loaded into memory.
  • When WSClean and EveryBeam use different aocommon versions, the two aocommon::FitsReader::initialize functions may not be compatible and undefined behavior and/or errors will occur.

When hiding all symbols, EveryBeam does not expose functions from aocommon anymore and always uses the functions that are compiled in the EveryBeam library.

Merge request reports