You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fbc: sf.net # 483 fblite: Can't call LEN with nested WITH block string member
- Also shows up in qb dialect between `__with : end __with` block since both the qb and fblite dialects support periods in variable names.
- with outer: len(.inner.member): end with, is incorrectly seen as len( outer.'inner.member' ) where 'inner.member' is taken as the full name of the member of outer.
- this bug is due to `CTypeOrExpression()` function looking ahead for a right parenthesis without specifying the `LEXCHECK_NOPERIODS` option. The look ahead token is cached and when the logic falls though, the parser no longer has access to the individual identifiers in the expression and treats it as all one identifier
Example:
#lang "fblite" '' or "qb" or "fb"
#ifndef __with
#define __with with
#endif
type inner_t
member as string
end type
type outer_t
inner as inner_t
end type
dim outer as outer_t
outer.inner.member = "blarg"
? len( outer.inner.member ) '' 5
__with outer
? len(.inner.member) '' 5
end __with
__with outer.inner
? len(.member) '' 5
end __with
Copy file name to clipboardExpand all lines: changelog.txt
+1Lines changed: 1 addition & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -41,6 +41,7 @@ Version 1.09.0
41
41
- gfxlib2: fix d2d scaling issues for high dpi (adeyblue)
42
42
- fbc: improve error message on statement between SELECT and first CASE inside a subroutine and don't allow CONST/ENUM between any SELECT & first CASE.
43
43
- sf.net #843: Implicit casting of argument to string works for Instr() and Mid() but not for Left() and Right()
44
+
- sf.net #483 fblite: Can't call LEN with nested WITH block string member
0 commit comments