Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
Ocarina
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
2
Issues
2
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
Operations
Operations
Incidents
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
TASTE
Ocarina
Commits
5758ceb6
Commit
5758ceb6
authored
Mar 22, 2013
by
yoogx
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* Provide an error message in case ports of threads are not connected
For issue #10
parent
be277956
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
5 deletions
+20
-5
src/backends/ocarina-backends-pn-components.adb
src/backends/ocarina-backends-pn-components.adb
+20
-5
No files found.
src/backends/ocarina-backends-pn-components.adb
View file @
5758ceb6
...
...
@@ -2707,20 +2707,35 @@ package body Ocarina.Backends.PN.Components is
A_PN_Arc
:
Node_Id
;
Source_Point
:
Node_Id
;
Endpoint
:
Node_Id
;
Ports
:
List_Id
;
Build_Data_Port
:
Boolean
:=
Is_Data
;
begin
if
Is_In
(
Port_Instance
)
then
-- in port
Endpoint
:=
Port_Instance
;
Source_Point
:=
Item
(
AIN
.
First_Node
(
Get_Source_Ports
(
Port_Instance
)));
Ports
:=
Get_Source_Ports
(
Port_Instance
);
if
AINU
.
Is_Empty
(
Ports
)
then
Display_Located_Error
(
AIN
.
Loc
(
Port_Instance
),
"This IN port is not connected to any destination"
,
Fatal
=>
True
);
else
Source_Point
:=
Item
(
AIN
.
First_Node
(
Ports
));
end
if
;
else
-- out port
Source_Point
:=
Port_Instance
;
Endpoint
:=
Item
(
AIN
.
First_Node
(
Get_Destination_Ports
(
Port_Instance
)));
Ports
:=
Get_Destination_Ports
(
Port_Instance
);
if
AINU
.
Is_Empty
(
Ports
)
then
Display_Located_Error
(
AIN
.
Loc
(
Port_Instance
),
"This OUT port is not connected to any destination"
,
Fatal
=>
True
);
else
Endpoint
:=
Item
(
AIN
.
First_Node
(
Ports
));
end
if
;
-- for out data ports only
-- to avoid endless fireable transition
...
...
Write
Preview
Markdown
is supported
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