From: cas Date: Fri, 5 Nov 1999 18:28:10 +0000 (+0000) Subject: No comments X-Git-Url: http://git.dev.opencascade.org/gitweb/?a=commitdiff_plain;h=d1841b97820a098a80ecb901edeac3eccb8e026b;p=occt-wok.git No comments --- diff --git a/src/CDLFront/CDL.lex b/src/CDLFront/CDL.lex index 13d66dd..ab910ad 100755 --- a/src/CDLFront/CDL.lex +++ b/src/CDLFront/CDL.lex @@ -1,18 +1,29 @@ /*======================================================*/ -/*== CDL lexical analyzer. +/*== CDL lexical analyzer. */ /*======================================================*/ %{ #include #include - +#ifdef WNT +# include +#else +# include +#endif /* WNT */ #include void add_cpp_comment(int,char*); #define yylval CDLlval #include int CDLlineno; + +#ifndef YY_NO_UNPUT +# define YY_NO_UNPUT +#endif /* YY_NO_UNPUT */ + +extern void CDLerror ( char* ); + %} @@ -196,31 +207,31 @@ static EndComment() /* Returns the last identifier */ char* YYident(){ - + return NULL; } /* Returns the last integer */ char* YYinteger(){ - + return NULL; } /* Returns the last real */ char* YYreal(){ - + return NULL; } /* Returns the last literal */ char* YYliteral(){ - + return NULL; } /* Returns the last String */ char* YYstring(){ - + return NULL; } /* Returns the last comment diff --git a/src/CDLFront/CDL.yacc b/src/CDLFront/CDL.yacc index 2c50d02..27d478d 100755 --- a/src/CDLFront/CDL.yacc +++ b/src/CDLFront/CDL.yacc @@ -22,6 +22,14 @@ #define CDL_OBJ 4 #define CDL_LIBRARY 5 #define CDL_EXTERNAL 6 + +#include + +#include + +extern void CDLerror ( char* ); +extern int CDLlex ( void ); + %} /*=-=-=-= End of The needed includes and variabels =-=-=-=-=-=-=-=-=-=-=-=*/ diff --git a/src/CDLFront/CDLFront.cxx b/src/CDLFront/CDLFront.cxx index 3d30d98..d982626 100755 --- a/src/CDLFront/CDLFront.cxx +++ b/src/CDLFront/CDLFront.cxx @@ -84,7 +84,6 @@ extern "C" { void CDL_InitVariable(); -static char *YY_fileName=""; static int YY_nb_error; static int YY_nb_warning; static Handle(TCollection_HAsciiString) CDLFileName; @@ -584,7 +583,7 @@ char *TypeCompletion(char *aName) { Handle(TColStd_HSequenceOfHAsciiString) aSeqOfPackage; Handle(TCollection_HAsciiString) aFullName = new TCollection_HAsciiString; - Standard_Integer i,pos; + Standard_Integer i; if (Current_Entity == CDL_GENCLASS || Current_Entity == CDL_STDCLASS) { Handle(TCollection_HAsciiString) aPackageName, thethetypename = new TCollection_HAsciiString(aName); @@ -2455,11 +2454,11 @@ void Param_Begin() aParam->Type(athetypename,aPackName); if (!ParamValue.IsNull()) { - MS_TypeOfValue pt; + MS_TypeOfValue pt = MS_INTEGER; MS_ParamWithValue *pwv; switch (ParamType) { - case INTEGER: pt = MS_INTEGER; + case INTEGER: break; case REAL: pt = MS_REAL; break; @@ -2615,7 +2614,7 @@ void Set_Any() } -extern "C" CDLparse(); +extern "C" int CDLparse(); void CDL_Main() @@ -2673,7 +2672,7 @@ int CDLTranslate(const Handle(MS_MetaSchema)& aMetaSchema, const Handle(TColStd_HSequenceOfHAsciiString)& anInstList, const Handle(TColStd_HSequenceOfHAsciiString)& anGenList) { - Standard_Integer ErrorLevel = 0; + volatile Standard_Integer ErrorLevel = 0; CDL_InitVariable();