@@ -565,7 +565,7 @@ static int addElementsOfClass(
565565 MetadataBuildingContext context ) {
566566 int idPropertyCounter = 0 ;
567567 for ( XProperty property : propertyContainer .propertyIterator () ) {
568- idPropertyCounter += addProperty ( propertyContainer , property , elements , context );
568+ idPropertyCounter += addProperty ( propertyContainer , property , elements , context , idPropertyCounter );
569569 }
570570 return idPropertyCounter ;
571571 }
@@ -574,20 +574,19 @@ private static int addProperty(
574574 PropertyContainer propertyContainer ,
575575 XProperty property ,
576576 List <PropertyData > inFlightPropertyDataList ,
577- MetadataBuildingContext context ) {
577+ MetadataBuildingContext context , int idPropertyCounter ) {
578578 // see if inFlightPropertyDataList already contains a PropertyData for this name,
579579 // and if so, skip it..
580580 for ( PropertyData propertyData : inFlightPropertyDataList ) {
581581 if ( propertyData .getPropertyName ().equals ( property .getName () ) ) {
582582 checkIdProperty ( property , propertyData );
583583 // EARLY EXIT!!!
584- return 0 ;
584+ return idPropertyCounter ;
585585 }
586586 }
587587
588588 final XClass declaringClass = propertyContainer .getDeclaringClass ();
589589 final XClass entity = propertyContainer .getEntityAtStake ();
590- int idPropertyCounter = 0 ;
591590 final PropertyData propertyAnnotatedElement = new PropertyInferredData (
592591 declaringClass ,
593592 property ,
0 commit comments