Skip to content

Program template could be clearer #17

Description

@martinboers

In the Visual Studio extension for C# (version 2022.6), when a new C# Program is added to a project, the template includes this code section:

   [Program]
    public class Program1
    {
        // Use the attributes [Global] and either [InputPort] or [OutputPort] to mark fields, 
        // that should exchange data with other IEC- or C#-Programs
        [Global, OutputPort]
        public int a = 1;
        [Global, InputPort]
        public int b = 2;
        public int c = 3;
           :

This gives the impression that the variables b and c are both InputPort variables, when in fact only b is an input port variable.

Perhaps this could be made clearer in the template, maybe with a comment after the declaration of variable c.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions