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

Update concerto-analysis rules to analyse aliased imports #869

Open
ekarademir opened this issue Jun 25, 2024 · 3 comments
Open

Update concerto-analysis rules to analyse aliased imports #869

ekarademir opened this issue Jun 25, 2024 · 3 comments
Milestone

Comments

@ekarademir
Copy link
Contributor

ekarademir commented Jun 25, 2024

Related analysers are probably these

  • Properties
  • Class declarations that extend an imported type
  • Import statements
@ekarademir ekarademir added this to the Import Alias milestone Jun 25, 2024
@ekarademir
Copy link
Contributor Author

  • Is aliasing just a syntactic change? So should it be ignored in analysis?
  • Or should it at least cause a patch change

Are the following the same

import com.example.foo@1.0.0.{Bar}

concept Animal {
  o Bar leg
}
import com.example.foo@1.0.0.{Bar as baz}

concept Animal {
  o baz leg
}

@salujajaskeerat
Copy link
Contributor

The current version of concerto-analysis only analyses the semantic structure of a model file. Whereas aliasing a type is only a syntactic change.

Also, there is no import factory at present.

Handling the above would require us to create an import factory.

Pros of analysing aliased imports:

  • we can label the alias changes as patch changes; this would explicitly tell the user that he has made an alias change.

cons of analysing aliased imports

  • aliasing a type is only a syntactic change, it does not change anything semantically

@ekarademir
Copy link
Contributor Author

Our BDFL decided this will be a patch change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: In Progress
Development

No branches or pull requests

2 participants