package test declare Annot fld : int @Annot end The packagebuilder type resolver will confuse the annotation with the declared class and throw exceptions (varies depending on optional import statements)
Fixed by https://github.com/droolsjbpm/drools/commit/c20957b873f5c03bbb5b90cbc571ce420704f052
Verified on BRMS 6.0.0 ER5.