[COMPILER]
* NEW: The Begins and Ends operator of course. * BUG: Fix a crash when compiling a line beginning with the Read instruction. git-svn-id: svn://localhost/gambas/trunk@2366 867c0c6c-44f3-4631-809d-bfa615b0a4ec
This commit is contained in:
parent
c17951fcd3
commit
d35c59c763
4 changed files with 21 additions and 4 deletions
|
@ -1,5 +1,5 @@
|
|||
# Gambas Project File 3.0
|
||||
# Compiled with Gambas 2.99.0 (r2317)
|
||||
# Compiled with Gambas 2.99.0 (r2352)
|
||||
Title=Gambas documentation CGI script
|
||||
Startup=Main
|
||||
Icon=help.png
|
||||
|
|
|
@ -982,7 +982,7 @@ Private Function Encode(sText As String) As String
|
|||
$sRes &= GetVersion()
|
||||
Continue
|
||||
|
||||
Case "only-in"
|
||||
Case "only-in", "only"
|
||||
$sRes &= GetOnlyIn(sArg)
|
||||
Continue
|
||||
|
||||
|
|
|
@ -550,7 +550,9 @@ static void add_identifier(bool no_res)
|
|||
last_type = (flag & RSF_ILT) != 0;
|
||||
if (flag & RSF_ILDD)
|
||||
{
|
||||
if (RES_get_ident_flag(PATTERN_index(get_last_last_pattern())) & RSF_ILD)
|
||||
PATTERN last_last_pattern = get_last_last_pattern();
|
||||
|
||||
if (PATTERN_is_reserved(last_last_pattern) && RES_get_ident_flag(PATTERN_index(last_last_pattern)) & RSF_ILD)
|
||||
last_declare = TRUE;
|
||||
flag &= ~RSF_ILDD; // flag == 0 means we can read a subroutine!
|
||||
}
|
||||
|
|
|
@ -234,6 +234,14 @@ static void add_pattern(int type, int index)
|
|||
|
||||
#endif
|
||||
|
||||
static PATTERN get_last_last_pattern()
|
||||
{
|
||||
if (EVAL->pattern_count > 1)
|
||||
return EVAL->pattern[EVAL->pattern_count - 2];
|
||||
else
|
||||
return NULL_PATTERN;
|
||||
}
|
||||
|
||||
static PATTERN get_last_pattern()
|
||||
{
|
||||
if (EVAL->pattern_count > 0)
|
||||
|
@ -446,7 +454,14 @@ static void add_identifier(bool no_res)
|
|||
last_func = (flag & RSF_ILF) != 0;
|
||||
last_declare = (flag & RSF_ILD) != 0;
|
||||
last_type = (flag & RSF_ILT) != 0;
|
||||
//last_event = flag & RSF_ILE;
|
||||
if (flag & RSF_ILDD)
|
||||
{
|
||||
PATTERN last_last_pattern = get_last_last_pattern();
|
||||
|
||||
if (PATTERN_is_reserved(last_last_pattern) && RES_get_ident_flag(PATTERN_index(last_last_pattern)) & RSF_ILD)
|
||||
last_declare = TRUE;
|
||||
flag &= ~RSF_ILDD; // flag == 0 means we can read a subroutine!
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue