Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
TASTE
OpenGEODE
Commits
9e1defb0
Commit
9e1defb0
authored
Feb 16, 2018
by
Maxime Perrotin
Browse files
Properly find fields in lookup table
parent
ceeb965b
Changes
1
Hide whitespace changes
Inline
Side-by-side
opengeode/ogParser.py
View file @
9e1defb0
...
...
@@ -1074,8 +1074,10 @@ def fix_expression_types(expr, context): # type: -> [warnings]
for
field
,
fd_expr
in
expr
.
right
.
value
.
viewitems
():
# if fd_expr.exprType == UNKNOWN_TYPE:
try
:
expected_type
=
asn_type
.
Children
.
get
(
field
.
lower
().
replace
(
'_'
,
'-'
)).
type
for
spelling
in
asn_type
.
Children
:
if
field
.
lower
().
replace
(
'_'
,
'-'
)
==
spelling
.
lower
():
break
expected_type
=
asn_type
.
Children
[
spelling
].
type
except
AttributeError
:
raise
TypeError
(
'Field not found: '
+
field
)
check_expr
=
ogAST
.
ExprAssign
()
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment