One small side note (ticket #2882, commit #2883):
In processor/src/main/resources/org/mapstruct/ap/internal/model/macro/CommonMacros.ftl we pass down targetPropertyName=ext.targetPropertyName and targetType=ext.targetType in <#macro handleSourceReferenceNullCheck>
Correction for targetType=ext.targetType is missing in <#macro handleLocalVarNullCheck needs_explicit_local_var> or it will fail in obscure usage of @TargetType when @Conditional method is defined in @Context variable.
Regards!
Originally posted by @ivlcic in #2834 (comment)