You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@xerces.apache.org by bu...@apache.org on 2002/05/08 09:13:18 UTC

DO NOT REPLY [Bug 8898] New: - SchemaElementDecl doesn't compile with Intel C++ for IA32

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=8898>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=8898

SchemaElementDecl doesn't compile with Intel C++ for IA32

           Summary: SchemaElementDecl doesn't compile with Intel C++ for
                    IA32
           Product: Xerces-C++
           Version: 1.7.0
          Platform: PC
        OS/Version: Other
            Status: NEW
          Severity: Minor
          Priority: Other
         Component: Validating Parser (Schema) (Xerces 1.5 or up only)
        AssignedTo: xerces-c-dev@xml.apache.org
        ReportedBy: carnold@houston.rr.com


Intel C++ Version 5 complains about this unreachable line
that attempts to return a XMLAttDefList& to NULL:

     return *(XMLAttDefList*)0 ;

It is fairly easy to change the method to eliminate that
line entirely.




Index: SchemaElementDecl.cpp
===================================================================
RCS file: /home/cvspublic/xml-
xerces/c/src/xercesc/validators/schema/SchemaElementDecl.cpp,v
retrieving revision 1.3
diff -u -r1.3 SchemaElementDecl.cpp
--- SchemaElementDecl.cpp	21 Mar 2002 16:31:43 -0000	1.3
+++ SchemaElementDecl.cpp	8 May 2002 07:03:49 -0000
@@ -264,14 +264,10 @@
     if (fXsiComplexTypeInfo) {
         return fXsiComplexTypeInfo->getAttDefList();
     }
-    else if (fComplexTypeInfo) {
-        return fComplexTypeInfo->getAttDefList();
-    }
-    else {
+    else if (!fComplexTypeInfo) {
         ThrowXML(RuntimeException, XMLExcepts::DV_InvalidOperation);
     }
-
-    return *(XMLAttDefList*)0 ;
+    return fComplexTypeInfo->getAttDefList();
 }

---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-c-dev-help@xml.apache.org