osate / osate2

Open Source AADL2 Tool Environment
http://osate.org
Eclipse Public License 2.0
39 stars 8 forks source link

Why is feature connection between ports legal but not port connection? #2534

Closed stevevestal closed 3 years ago

stevevestal commented 3 years ago

Summary

A port connection between ports inside feature groups gets an error, but changing it to a feature connection is acceptable.

Expected and Current Behavior

I would have thought a port connection from a port to a port would be legal.

Steps to Reproduce

See example below.

-- See comments below.  Just seems odd.
package NestedConnection
public

    feature group aGroup
        features
            inPort: in data port;
    end aGroup;

    system HasOutPort
        features
            outPort: out data port;
    end HasOutPort;

    system HasInGroup
        features
            inGroup: feature group aGroup;
    end HasInGroup;

    system NestedConnection
    end NestedConnection;

    system implementation NestedConnection.Impl
        subcomponents
            sysOut: system HasOutPort;
            sysIn: system HasInGroup;
        connections
            -- It seems odd that the following is legal ...
            out_in_feature: feature sysOut.outPort -> sysIn.inGroup.inPort;
            -- ... but the following is not.
            out_in_port: port sysOut.outPort -> sysIn.inGroup.inPort;           
    end NestedConnection.Impl;

end NestedConnection;

Environment

lwrage commented 3 years ago

Please ask questions in the google group instead of filing an issue. This is as specified in the AADL 2.2 standard.