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
c15d7ab4
Commit
c15d7ab4
authored
Mar 25, 2019
by
Maxime Perrotin
Browse files
Add all associations
parent
afad3240
Changes
1
Show whitespace changes
Inline
Side-by-side
src/taste-concurrency_view.adb
View file @
c15d7ab4
...
...
@@ -184,10 +184,11 @@ package body TASTE.Concurrency_View is
(
Parse
(
Path
&
"/trigger.tmplt"
,
Trig_Tmpl
))
=
"TRUE"
);
function
Generate_Partition
(
Partition
:
CV_Partition
)
return
Translate_Set
return
String
is
Threads
:
Tag
;
Blocks
:
Tag
;
Partition_Assoc
:
Translate_Set
;
begin
for
T
of
Partition
.
Threads
loop
declare
...
...
@@ -222,28 +223,28 @@ package body TASTE.Concurrency_View is
String
'(
Parse
(
Path
&
"/block.tmplt"
,
Block_Assoc
));
end
;
end
loop
;
return
Translate_Set
'(
+
Assoc
(
"Threads"
,
Threads
)
&
Assoc
(
"Blocks"
,
Blocks
));
Partition_Assoc
:=
+
Assoc
(
"Threads"
,
Threads
)
&
Assoc
(
"Blocks"
,
Blocks
);
return
Parse
(
Path
&
"/partition.tmplt"
,
Partition_Assoc
);
end
Generate_Partition
;
Partitions
:
Tag
;
Node_Assoc
:
Translate_Set
;
begin
-- A node contains partitions, we must render them all separately
-- using their own templates (threads and blocks), and then call
-- use the node template with these tags.
if
Trigger
then
for
Partition
of
CV
.
Nodes
(
Node_Name
).
Partitions
loop
declare
Partition_Assoc
:
constant
Translate_Set
:=
Generate_
Partition
(
Partition
);
begin
Partitions
:=
Partitions
&
Generate_Partition
(
Partition
);
end
loop
;
Node_Assoc
:=
+
Assoc
(
"
Partition
s"
,
Partition
s
);
Put_Info
(
"Generating from "
&
Path
);
Create
(
File
=>
Output_File
,
Mode
=>
Out_File
,
Name
=>
Output_Dir
&
File_Name
);
Put_Line
(
Output_File
,
Parse
(
Path
&
"/node.tmplt"
,
Partition
_Assoc
));
Parse
(
Path
&
"/node.tmplt"
,
Node
_Assoc
));
Close
(
Output_File
);
end
;
end
loop
;
end
if
;
end
;
<<continue>>
...
...
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