analyser: checking public declarations using non-public types