Picks the Polygon sourceType for a file: the value declared in Config.json wins; otherwise it is inferred from the extension.
sourceType
Config.json
File name (extension decides the fallback)
Optional
sourceType from the config entry, if any
Polygon compiler identifier (e.g. cpp.gcc14-64-msys2-g++23)
cpp.gcc14-64-msys2-g++23
resolveSourceType('sol.cc'); // 'cpp.g++17'resolveSourceType('sol.cpp', 'cpp.gcc14-64-msys2-g++23'); // declared winsresolveSourceType('Sol.java'); // 'java11' Copy
resolveSourceType('sol.cc'); // 'cpp.g++17'resolveSourceType('sol.cpp', 'cpp.gcc14-64-msys2-g++23'); // declared winsresolveSourceType('Sol.java'); // 'java11'
Picks the Polygon
sourceTypefor a file: the value declared inConfig.jsonwins; otherwise it is inferred from the extension.