Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Get rid of the obviously irrelevant parts of the grammar #2465

Merged
merged 10 commits into from
Jan 9, 2020

Conversation

henrikt-ma
Copy link
Collaborator

The goal of this PR is to get rid of the obviously irrelevant parts of the grammar. At the time of writing, the branch to be merged doesn't yet make any changes to the grammar. The idea is the working group should introduce these changes collaboratively, and everybody is invited to contribute.

@gkurzbach
Copy link
Collaborator

composition →
  (generic-element ;)*
  ( public (generic-element ;)*
  | protected (generic-element ;)*
  | initial? equation ( equation ; )*
  | initial? algorithm ( statement ; )*

When collecting equation sections from vectorized components it might be useful to allow dimensions after the equation and algorithm keyword, if someone wants to retain this structural information to take advantages from that. In this case the equations can be left unchanged, else the equations have to be duplicated and enriched with the right component indices. E.g.:
'equation [3] ....'
or in syntax:

  | initial? equation _array-subscripts_? ( equation ; )*
  | initial? algorithm _array-subscripts_? ( statement ; )*

This would be an extension of Modelica syntax.

  )*
  ( external language-specification?
   external-function-call? annotation-comment? ;
  )?
  ( annotation-comment ; )?

@henrikt-ma
Copy link
Collaborator Author

When collecting equation sections from vectorized components it might be useful to allow dimensions after the equation and algorithm keyword

I like the idea, and I think it belongs to the item I put in the roadmap section Flat Modelica 2.0.

@henrikt-ma henrikt-ma marked this pull request as ready for review January 7, 2020 20:46
@henrikt-ma
Copy link
Collaborator Author

I might remember wrong, but I thought we decided to merge this at the last web meeting. Short of evidence thereof, I am at least marking this as Ready for review now, as I think the discussion has slowed down enough.

@olivleno
Copy link
Collaborator

olivleno commented Jan 9, 2020

As decided in the web meeting, this all done for now and shall be merged.

@henrikt-ma henrikt-ma merged commit 927e0e0 into MCP/0031 Jan 9, 2020
@henrikt-ma henrikt-ma deleted the MCP/0031+irrelevant-grammar branch January 10, 2020 06:34
@HansOlsson HansOlsson added the MCP0031 Base Modelica and MLS modularization (MCP-0031) label Dec 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
MCP0031 Base Modelica and MLS modularization (MCP-0031)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants