Skip to content

Property associations for behavior variables are not supported #2190

Closed

Description

@Etienne13

Summary

In BA, property associations can be attached to behavior variables. This is particularly useful for variables initialization, as mentioned in issue #2184

Steps to Reproduce

The following model is not parsed correctly by the BA plugin

package issue2184_InitialValue
public
	with Base_Types;
	with Data_Model;
	
	process top
		features
			o1: out data port Base_Types::Integer_32;

		annex behavior_specification {**
          variables
            tmp :  Base_Types::Integer_32 {Data_Model::Initial_Value => ("1");};
          states
            a : initial final state;
          transitions
            t : a -[]-> a {
              o1 := tmp
            };
        **};
	end top;

	
end issue2184_InitialValue;

Environment

  • OSATE Version: Nightly
  • Operating System: Linux

Activity

  1. self-assigned this
    on Feb 6, 2020
  2. Etienne13 commented on Feb 6, 2020

    @Etienne13
    ContributorAuthor

    @lwrage I have to parse property associations with records. Is there a utility function to retreive the property object of the record from its name and the property it is associated with?
    For example, I have a property association my_prop => [f1=>1;]; how to retrieve "f1" from its name (a String) and the object corresponding to my_prop?

  3. Etienne13 commented on Feb 7, 2020

    @Etienne13
    ContributorAuthor

    @lwrage I found how to do it just by getting the property type of my_prop, casting the type into a RecordTye and then taking the content. I don't think we need a utility function for this.

  4. added this to the 2.7.1 milestone on Feb 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions