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

Generate code including using statements #507

Open
mci-kmd opened this issue Jun 19, 2023 · 1 comment
Open

Generate code including using statements #507

mci-kmd opened this issue Jun 19, 2023 · 1 comment
Labels
enhancement New feature or request

Comments

@mci-kmd
Copy link

mci-kmd commented Jun 19, 2023

Is your feature request related to a problem? Please describe.
The generated code does not import any namespaces. This means that every reference to a type is fully qualified. This greatly reduces the readability of the code, especially when you use long namespaces.

Describe the solution you'd like
It would be greate if all the relevant using statements could be added to ensure that types can be referenced without namespace qualification. I realize that the current solution sidesteps the issue of class ambiguity, for example when mapping between types of the same name. This could be solved with an aliasing convention, though I'm not sure what the best one would be. A better approach would probably be just to fall back to the old approach for these cases.

@latonz latonz added the enhancement New feature or request label Jun 19, 2023
@latonz
Copy link
Contributor

latonz commented Jun 19, 2023

Thank you for opening this issue. I think it could definitely improve the readability of the generated code. We'll keep the issue around but currently other features have higher priority.
If you are interested in implementing this, feel free to contribute a concept on how this could be implemented to this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants