olabusayoT commented on a change in pull request #237: Fixes DAFFODIL-2142 URL: https://github.com/apache/incubator-daffodil/pull/237#discussion_r294996656
########## File path: daffodil-core/src/main/scala/org/apache/daffodil/dsom/ComplexTypes.scala ########## @@ -52,8 +55,26 @@ abstract class ComplexTypeBase(xmlArg: Node, parentArg: SchemaComponent) xmlChildren.flatMap { xmlChild => { - val g = ModelGroupFactory(xmlChild, this, 1, false) // discards unwanted text nodes also. - g + xmlChild match { + case <annotation>{ annotationChildren @ _* }</annotation> => { + val dais = annotationChildren.find { ai => + ai.attribute("source") match { + case Some(n) => n.text.contains("ogf") && n.text.contains("dfdl") + case _ => false + } + } + if (dais != None) { + this.SDW(WarnID.InvalidAnnotationPoint, "complexType is not a valid annotation point. Annotation dropped.") Review comment: Updates made ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services