MWS_SRX644: migrate branch mws_srx644 -> HEAD

This commit is contained in:
Jens-Heiner Rechtien
2003-03-26 11:11:12 +00:00
parent c082fe0562
commit f8183bfe73
13 changed files with 73 additions and 70 deletions

View File

@@ -2,9 +2,9 @@
*
* $RCSfile: errorhandler.cxx,v $
*
* $Revision: 1.2 $
* $Revision: 1.3 $
*
* last change: $Author: jbu $ $Date: 2001-05-09 07:57:56 $
* last change: $Author: hr $ $Date: 2003-03-26 12:11:08 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -548,7 +548,7 @@ void ErrorHandler::warning2(WarningCode w, AstDeclaration* d1, AstDeclaration* d
void ErrorHandler::syntaxError(ParseState ps, sal_Int32 lineNumber, sal_Char* errmsg)
{
errorHeader(EIDL_SYNTAX_ERROR, lineNumber);
fprintf(stderr, "%s%s\n", parseStateToMessage(ps), errmsg + 11);
fprintf(stderr, "%s: %s\n", parseStateToMessage(ps), errmsg);
idlc()->incErrorCount();
}

View File

@@ -2,9 +2,9 @@
*
* $RCSfile: idlccompile.cxx,v $
*
* $Revision: 1.11 $
* $Revision: 1.12 $
*
* last change: $Author: hr $ $Date: 2002-02-21 11:31:12 $
* last change: $Author: hr $ $Date: 2003-03-26 12:11:08 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -85,7 +85,6 @@
#include <io.h>
#endif
#include <string.h>
#ifdef SAL_UNX
#include <unistd.h>
#if defined(MACOSX) || defined(FREEBSD) || defined(NETBSD)
@@ -173,10 +172,19 @@ OString makeTempName(const OString& prefix, const OString& postfix)
tmpPath = OUStringToOString(uTmpPath, RTL_TEXTENCODING_UTF8);
#if defined(SAL_W32) || defined(SAL_UNX)
strcpy(tmpFilePattern, tmpPath);
strcat(tmpFilePattern, PATH_SEPARATOR);
strcat(tmpFilePattern, prefix.getStr());
strcat(tmpFilePattern, "XXXXXX");
OSL_ASSERT( sizeof(tmpFilePattern) > ( strlen(tmpPath)
+ RTL_CONSTASCII_LENGTH(
PATH_SEPARATOR )
+ prefix.getLength()
+ RTL_CONSTASCII_LENGTH(
"XXXXXX") ) );
tmpFilePattern[ sizeof(tmpFilePattern)-1 ] = '\0';
strncpy(tmpFilePattern, tmpPath, sizeof(tmpFilePattern)-1);
strncat(tmpFilePattern, PATH_SEPARATOR, sizeof(tmpFilePattern)-1-strlen(tmpFilePattern));
strncat(tmpFilePattern, prefix.getStr(), sizeof(tmpFilePattern)-1-strlen(tmpFilePattern));
strncat(tmpFilePattern, "XXXXXX", sizeof(tmpFilePattern)-1-strlen(tmpFilePattern));
#ifdef SAL_UNX
int nDescriptor = mkstemp(tmpFilePattern);
@@ -195,11 +203,11 @@ OString makeTempName(const OString& prefix, const OString& postfix)
Is the postfix necessarry?
*/
// if ( postfix.getLength() )
// strcat(tmpFilePattern, postfix.getStr());
// strncat(tmpFilePattern, postfix.getStr(), sizeof(tmpFilePattern)-1-strlen(tmpFilePattern));
#endif
#ifdef __OS2__
strcpy(tmpFilePattern, tempnam(NULL, prefix.getStr());
strncpy(tmpFilePattern, tempnam(NULL, prefix.getStr()), sizeof(tmpFilePattern)-1);
#endif
return OString(tmpFilePattern);

View File

@@ -2,9 +2,9 @@
*
* $RCSfile: idlcproduce.cxx,v $
*
* $Revision: 1.7 $
* $Revision: 1.8 $
*
* last change: $Author: hr $ $Date: 2002-02-21 11:31:12 $
* last change: $Author: hr $ $Date: 2003-03-26 12:11:08 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -83,7 +83,6 @@
#include <errno.h>
#endif
#include <string.h>
#ifdef SAL_UNX
#include <unistd.h>
#include <sys/stat.h>

View File

@@ -2,9 +2,9 @@
#
# $RCSfile: makefile.mk,v $
#
# $Revision: 1.6 $
# $Revision: 1.7 $
#
# last change: $Author: hjs $ $Date: 2002-07-17 10:52:00 $
# last change: $Author: hr $ $Date: 2003-03-26 12:11:09 $
#
# The Contents of this file are made available subject to the terms of
# either of the following licenses
@@ -147,3 +147,7 @@ $(MISC)$/stripped_scanner.ll : scanner.ll
$(MISC)$/scanner.cxx: $(MISC)$/stripped_scanner.ll
+flex -o$(MISC)$/scanner.cxx $(MISC)$/stripped_scanner.ll
# JSC: Please do not remove this lines !!
#$(MISC)$/parser.cxx: parser.y
# +bison -v -d -o$(MISC)$/parser.cxx parser.y
# +$(COPY) $(MISC)$/parser.cxx.h $(OUT)$/inc$/parser.hxx

View File

@@ -2,9 +2,9 @@
*
* $RCSfile: options.cxx,v $
*
* $Revision: 1.6 $
* $Revision: 1.7 $
*
* last change: $Author: hr $ $Date: 2002-02-21 11:31:12 $
* last change: $Author: hr $ $Date: 2003-03-26 12:11:09 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -59,7 +59,6 @@
*
************************************************************************/
#include <stdio.h>
#include <string.h>
#ifndef _IDLC_OPTIONS_HXX_
#include <idlc/options.hxx>

View File

@@ -2,9 +2,9 @@
*
* $RCSfile: parser.y,v $
*
* $Revision: 1.2 $
* $Revision: 1.3 $
*
* last change: $Author: obo $ $Date: 2002-10-29 12:54:35 $
* last change: $Author: hr $ $Date: 2003-03-26 12:11:09 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -144,10 +144,6 @@ int fprintf(FILE* stream, const char* format, ...)
return res;
}
/*
Following code not for msvc7.net compiler
*/
#ifndef M1300
void* malloc( size_t size )
{
return ::malloc(size);
@@ -157,7 +153,6 @@ void free( void *memblock )
{
::free(memblock);
}
#endif
};
#endif
@@ -527,7 +522,8 @@ interface_dcl :
*/
else
{
pForward->setInheritedInterfaces(*$1->getInherits());
if ( $1->getInherits() )
pForward->setInheritedInterfaces(*$1->getInherits());
pForward->setImported(pInterface->isImported());
pForward->setInMainfile(pInterface->isInMainfile());
@@ -790,6 +786,11 @@ opt_attrflag :
idlc()->setParseState(PS_RemoveableSeen);
$$ = AF_REMOVEABLE;
}
| error ']'
{
yyerror("unknown property|attribute flag");
yyerrok;
}
;
operation :
@@ -1000,7 +1001,8 @@ constants_export :
{
idlc()->setParseState(PS_ConstantDeclSeen);
}
';'
';' {};
const_dcl :
IDL_CONST
@@ -1321,7 +1323,7 @@ exception_dcl :
* Push the scope of the exception on the scopes stack
*/
idlc()->scopes()->push(pExcept);
delete $1
delete $1;
}
'{'
{
@@ -1710,10 +1712,10 @@ type_dcl :
{
idlc()->setParseState(PS_TypedefSeen);
}
type_declarator
| struct_type
| union_type
| enum_type
type_declarator {}
| struct_type {}
| union_type {}
| enum_type {}
;
type_declarator :

View File

@@ -2,9 +2,9 @@
*
* $RCSfile: cpp.c,v $
*
* $Revision: 1.1 $
* $Revision: 1.2 $
*
* last change: $Author: jsc $ $Date: 2001-03-15 12:48:45 $
* last change: $Author: hr $ $Date: 2003-03-26 12:11:11 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -77,7 +77,7 @@ int ifdepth;
int ifsatisfied[NIF];
int skipping;
char rcsid[] = "$Version 1.2 $ $Revision: 1.1 $ $Date: 2001-03-15 12:48:45 $";
char rcsid[] = "$Version 1.2 $ $Revision: 1.2 $ $Date: 2003-03-26 12:11:11 $";
int realargc;
char* realargv[512];
@@ -170,7 +170,7 @@ int main(int argc, char **argv)
void
process(Tokenrow * trp)
{
int anymacros = 0; /* S390: XDBX st<73>rzt ab! */
int anymacros = 0;
for (;;)
{

View File

@@ -2,9 +2,9 @@
*
* $RCSfile: include.c,v $
*
* $Revision: 1.1 $
* $Revision: 1.2 $
*
* last change: $Author: jsc $ $Date: 2001-03-15 12:48:45 $
* last change: $Author: hr $ $Date: 2003-03-26 12:11:11 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -63,7 +63,7 @@
#include <string.h>
#include <fcntl.h>
#if (defined(_WIN32) || defined(_MSDOS) || defined(__IBMC__)) && !(defined S390)
#if (defined(_WIN32) || defined(_MSDOS) || defined(__IBMC__))
# include <io.h>
#else
# include <unistd.h>

View File

@@ -2,9 +2,9 @@
*
* $RCSfile: lex.c,v $
*
* $Revision: 1.1 $
* $Revision: 1.2 $
*
* last change: $Author: jsc $ $Date: 2001-03-15 12:48:45 $
* last change: $Author: hr $ $Date: 2003-03-26 12:11:11 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -61,7 +61,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#if (defined(_WIN32) || defined(_MSDOS) || defined(__IBMC__)) && !(defined S390)
#if (defined(_WIN32) || defined(_MSDOS) || defined(__IBMC__))
#include <io.h>
#else
#include <unistd.h>
@@ -97,11 +97,7 @@
#define C_ALPH 2
#define C_NUM 3
#define C_EOF 4
#ifdef S390
#define C_XX 6
#else
#define C_XX 5
#endif
enum state
{
@@ -328,12 +324,8 @@ void
continue;
case C_ALPH:
for (j = 0; j <= 256; j++)
#ifdef S390
if( isalpha( j ) || (j == '_') )
#else
if ('a' <= j && j <= 'z' || 'A' <= j && j <= 'Z'
|| j == '_')
#endif
bigfsm[j][fp->state] = nstate;
continue;
case C_NUM:
@@ -411,7 +403,7 @@ int
}
}
maxp = &trp->bp[trp->max];
runelen = 1; /* S390: XDBX st<73>rzt ab! */
runelen = 1;
for (;;)
{
continue2:
@@ -430,7 +422,7 @@ continue2:
{
oldstate = state;
c = *ip; /* S390: XDBX st<73>rzt (gelegentlich) ab! */
c = *ip;
if ((state = bigfsm[c][state]) >= 0)
{
@@ -476,7 +468,7 @@ continue2:
if (c == '\n')
{
while (s->inp + 1 >= s->inl && fillbuf(s) != EOF); /* S390: XDBX st<73>rzt (manchmal) ab! */
while (s->inp + 1 >= s->inl && fillbuf(s) != EOF);
if (s->inp[1] == '\r')
{

View File

@@ -2,9 +2,9 @@
#
# $RCSfile: makefile.mk,v $
#
# $Revision: 1.2 $
# $Revision: 1.3 $
#
# last change: $Author: hr $ $Date: 2001-09-26 14:42:47 $
# last change: $Author: hr $ $Date: 2003-03-26 12:11:11 $
#
# The Contents of this file are made available subject to the terms of
# either of the following licenses
@@ -70,10 +70,9 @@ TARGETTHREAD=ST
# --- Settings -----------------------------------------------------
NO_DEFAULT_STL=TRUE
LIBSALCPPRT=$(0)
.INCLUDE : svpre.mk
.INCLUDE : settings.mk
.INCLUDE : sv.mk
# --- Files --------------------------------------------------------

View File

@@ -2,9 +2,9 @@
*
* $RCSfile: tokens.c,v $
*
* $Revision: 1.1 $
* $Revision: 1.2 $
*
* last change: $Author: jsc $ $Date: 2001-03-15 12:48:46 $
* last change: $Author: hr $ $Date: 2003-03-26 12:11:12 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -62,7 +62,7 @@
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#if (defined(_WIN32) || defined(_MSDOS) || defined(__IBMC__)) && !(defined S390)
#if (defined(_WIN32) || defined(_MSDOS) || defined(__IBMC__))
#include <io.h>
#else
#include <unistd.h>

View File

@@ -2,9 +2,9 @@
*
* $RCSfile: unix.c,v $
*
* $Revision: 1.1 $
* $Revision: 1.2 $
*
* last change: $Author: jsc $ $Date: 2001-03-15 12:48:46 $
* last change: $Author: hr $ $Date: 2003-03-26 12:11:12 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -64,7 +64,7 @@
#include <string.h>
#include <ctype.h>
#include <fcntl.h>
#if (defined(_WIN32) || defined(_MSDOS) || defined(__IBMC__)) && !(defined S390)
#if (defined(_WIN32) || defined(_MSDOS) || defined(__IBMC__))
#include <io.h>
#else
#include <unistd.h>

View File

@@ -2,9 +2,9 @@
*
* $RCSfile: scanner.ll,v $
*
* $Revision: 1.6 $
* $Revision: 1.7 $
*
* last change: $Author: hjs $ $Date: 2002-03-06 13:25:45 $
* last change: $Author: hr $ $Date: 2003-03-26 12:11:09 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -329,9 +329,9 @@ oneway return IDL_ONEWAY;
return IDL_STRING_LITERAL;
}
("-")?{DIGIT}*(e|E){1}(("+"|"-")?{DIGIT}+)+(f|F)? |
("-")?"."{DIGIT}*((e|E)("+"|"-")?{DIGIT}+)?(f|F)? |
("-")?{DIGIT}*"."{DIGIT}*((e|E)("+"|"-")?{DIGIT}+)?(f|F)? {
("-")?{DIGIT}+(e|E){1}(("+"|"-")?{DIGIT}+)+(f|F)? |
("-")?"."{DIGIT}+((e|E)("+"|"-")?{DIGIT}+)?(f|F)? |
("-")?{DIGIT}*"."{DIGIT}+((e|E)("+"|"-")?{DIGIT}+)?(f|F)? {
yylval.dval = asciiToFloat( yytext );
return IDL_FLOATING_PT_LITERAL;
}