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
kazoo
Commits
391bc225
Commit
391bc225
authored
Nov 24, 2017
by
Maxime Perrotin
Browse files
Add placeholder to store functions context
parent
88970eed
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/parser_utils.adb
View file @
391bc225
...
...
@@ -629,6 +629,7 @@ package body Parser_Utils is
Name
:
constant
String
:=
AIN_Case
(
Func
);
Next_Prefix
:
constant
String
:=
Prefix
&
(
if
Prefix
'
Length
>
0
then
"."
else
""
)
&
Name
;
Terminal_Fn
:
Taste_Terminal_Function
;
begin
case
Get_Category_Of_Component
(
CI
)
is
...
...
@@ -640,16 +641,23 @@ package body Parser_Utils is
Func
=>
Inner
);
Inner
:=
AIN
.
Next_Node
(
Inner
);
end
loop
;
end
if
;
Routes_Map
.
Insert
(
Key
=>
Name
,
New_Item
=>
Parse_System_Connections
(
CI
));
-- Inner components may not be functions but properties
if
Res
/=
Functions
.
Empty_Vector
then
Routes_Map
.
Insert
(
Key
=>
Name
,
New_Item
=>
Parse_System_Connections
(
CI
));
end
if
;
end
if
;
if
No
(
AIN
.
Subcomponents
(
CI
))
or
Res
=
Functions
.
Empty_Vector
then
Res
:=
Res
&
Parse_Function
(
Prefix
=>
Prefix
,
Name
=>
Name
,
Inst
=>
CI
);
Terminal_Fn
:=
Parse_Function
(
Prefix
=>
Prefix
,
Name
=>
Name
,
Inst
=>
CI
);
Terminal_Fn
.
Context
:=
US
(
Name
);
Res
:=
Res
&
Terminal_Fn
;
end
if
;
when
others
=>
null
;
...
...
src/parser_utils.ads
View file @
391bc225
...
...
@@ -168,6 +168,7 @@ package Parser_Utils is
type
Taste_Terminal_Function
is
record
Name
:
Unbounded_String
;
Context
:
Unbounded_String
:=
Null_Unbounded_String
;
Prefix
:
Optional_Unbounded_String
:=
Nothing
;
Language
:
Supported_Source_Language
;
Zip_File
:
Optional_Unbounded_String
:=
Nothing
;
...
...
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