2001-12-03 10:45 UTC-0800 Ron Pinkas <ron@profit-master.com>

* contrib/dot/pp.prg
   * source/pp/ppcore.c
     ! Fixed Array Index support after '.' (Macro Terminator).
This commit is contained in:
Ron Pinkas
2001-01-03 17:33:49 +00:00
parent 1d698b2bf5
commit fa721257a4
3 changed files with 18 additions and 17 deletions

View File

@@ -1,20 +1,21 @@
2000-01-02 17:10 UTC-0800 Ron Pinkas <ron@profit-master.com>
2001-12-03 10:45 UTC-0800 Ron Pinkas <ron@profit-master.com>
* contrib/dot/pp.prg
* source/pp/ppcore.c
! Fixed Array Index support after '.' (Macro Terminator).
2001-01-02 17:10 UTC-0800 Ron Pinkas <ron@profit-master.com>
* source/compiler/genc.c
* Minor correction.
2000-01-02 10:00 UTC-0800 Ron Pinkas <ron@profit-master.com>
2001-01-02 10:00 UTC-0800 Ron Pinkas <ron@profit-master.com>
* source/compiler/harbour.l
+ Added support for inline C code.
2000-01-01 23:35 UTC-0800 Ron Pinkas <ron@profit-master.com>
2001-01-01 23:35 UTC-0800 Ron Pinkas <ron@profit-master.com>
* source/compiler/harbour.c
* Minor correction in hb_compInlineAdd()
2000-01-01 22:40 UTC-0800 Ron Pinkas <ron@profit-master.com>
2001-01-01 22:40 UTC-0800 Ron Pinkas <ron@profit-master.com>
* include/hberrors.h
* source/compiler/hbgenerr.c
+ Added: "Unterminated inline block in function: \'%s\'" and "Too many inline blocks"

View File

@@ -339,7 +339,7 @@ RETURN NIL
FUNCTION ProcessFile( sSource, sSwitch )
LOCAL hSource, sBuffer, sLine, nPosition, nNewLineAt, sExt
LOCAL hSource, sBuffer, sLine, nPosition, nNewLineAt, sExt, cPrev
LOCAL nLen, nMaxPos, cChar := '', nClose, nBase, nNext, nLine := 0
LOCAL sRight, nPath, nPaths := Len( asPaths ), nNewLine, bBlanks := .T.
@@ -655,7 +655,7 @@ FUNCTION ProcessFile( sSource, sSwitch )
ENDDO
CASE ( cChar == '[' )
IF cPrev $ "])}" .OR. ( cPrev == '_' .OR. ( cPrev >= 'A' .AND. cPrev <= 'Z' ) .OR. ( cPrev >= 'a' .AND. cPrev <= 'z' ) .OR. ( cPrev >= '0' .AND. cPrev <= '9' ) )
IF cPrev $ "])}." .OR. ( cPrev == '_' .OR. ( cPrev >= 'A' .AND. cPrev <= 'Z' ) .OR. ( cPrev >= 'a' .AND. cPrev <= 'z' ) .OR. ( cPrev >= '0' .AND. cPrev <= '9' ) )
sLine += cChar
nPosition++
LOOP
@@ -2018,7 +2018,7 @@ FUNCTION NextToken( sLine, bCheckRules )
IF ( s_cLastChar >= 'a' .AND. s_cLastChar <= 'z' ) .OR. ;
( s_cLastChar >= 'A' .AND. s_cLastChar <= 'Z' ) .OR. ;
( s_cLastChar >= '0' .AND. s_cLastChar <= '9' ) .OR. ;
s_cLastChar == '_' .OR. s_cLastChar $ ")}]"
s_cLastChar == '_' .OR. s_cLastChar $ ")}]."
sReturn := '['
@@ -2406,7 +2406,7 @@ FUNCTION NextExp( sLine, cType, aWords, aExp, sNextAnchor )
ENDIF
ENDIF
ELSEIF Right( sExp, 1 ) $ "}])" .AND. Left( sLine, 1 ) == '[' .AND. ( sNextAnchor != "[" ) /*.AND. At( ']', sLine ) < At( '[', SubStr( sLine, 2 ) ) */
ELSEIF Right( sExp, 1 ) $ "}])." .AND. Left( sLine, 1 ) == '[' .AND. ( sNextAnchor != "[" ) /*.AND. At( ']', sLine ) < At( '[', SubStr( sLine, 2 ) ) */
sExp += Left( sLine, 1 ) // Open
sLine := SubStr( sLine, 2 )

View File

@@ -1853,7 +1853,7 @@ static int getExpReal( char * expreal, char ** ptri, BOOL prlist, int maxrez, BO
State = ( StBr1==0 && StBr2==0 && StBr3==0 )? STATE_ID_END: STATE_BRACKET;
continue;
}
else if( **ptri == '[' && ( State == STATE_EXPRES || ( cLastChar != ')' && cLastChar != ']' && cLastChar != '}' && ! ISNAME( cLastChar ) ) ) )
else if( **ptri == '[' && ( State == STATE_EXPRES || ( strchr( ")]}.", cLastChar ) == NULL && ! ISNAME( cLastChar ) ) ) )
{
char *pString;
@@ -2678,7 +2678,7 @@ int hb_pp_RdStr( FILE * handl_i, char * buffer, int maxlen, BOOL lDropSpaces, ch
/* Ron Pinkas modified 2000-06-17
if( ISNAME(s_prevchar) || s_prevchar == ']' )
*/
if( ISNAME(s_prevchar) || s_prevchar == ']' || s_prevchar == ')' || s_prevchar == '}' )
if( ISNAME(s_prevchar) || strchr( ")]}.", s_prevchar ) )
s_ParseState = STATE_BRACKET;
else
s_ParseState = STATE_QUOTE3;
@@ -2831,7 +2831,7 @@ static int md_strAt( char * szSub, int lSubLen, char * szText, BOOL checkword, B
lPos++;
continue;
}
else if( bRule == FALSE && *(szText+lPos) == '[' && ( lPos == 0 || *(szText+lPos-1) != '\\' ) && cLastChar != ')' && cLastChar != ']' && cLastChar != '}' && ! ISNAME( cLastChar ) )
else if( bRule == FALSE && *(szText+lPos) == '[' && ( lPos == 0 || *(szText+lPos-1) != '\\' ) && strchr( ")]}.", cLastChar ) == NULL && ! ISNAME( cLastChar ) )
{
State = STATE_QUOTE3;
lPos++;
@@ -3095,7 +3095,7 @@ static int strotrim( char * stroka )
State = STATE_QUOTE2;
}
/* Ron Pinkas added 2000-11-05 */
else if( curc == '[' && ( cLastChar != ']' && cLastChar != ')' && cLastChar != '}' && ! ISNAME( cLastChar ) ) )
else if( curc == '[' && ( strchr( ")]}.", cLastChar ) == NULL && ! ISNAME( cLastChar ) ) )
{
State = STATE_QUOTE3;
}
@@ -3229,7 +3229,7 @@ static int NextName( char ** sSource, char * sDest )
State = STATE_QUOTE2;
}
/* Ron Pinkas added 2000-11-08 */
else if( **sSource == '[' && s_bArray == FALSE && cLastChar != ')' && cLastChar != ']' && cLastChar != '}' && ! ISNAME( cLastChar ) )
else if( **sSource == '[' && s_bArray == FALSE && strchr( ")]}.", cLastChar ) == NULL && ! ISNAME( cLastChar ) )
{
/* Ron Pinkas added 2000-11-08 */
pString = *sSource;
@@ -3314,7 +3314,7 @@ static int NextParm( char ** sSource, char * sDest )
{
State = STATE_QUOTE2;
}
else if( **sSource == '[' && cLastChar != ')' && cLastChar != ']' && cLastChar != '}' && ! ISNAME( cLastChar ) )
else if( **sSource == '[' && strchr( ")]}.", cLastChar ) == NULL && ! ISNAME( cLastChar ) )
{
State = STATE_QUOTE3;
}