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

Unused template parameter in model template #5488

Open
chunyu3 opened this issue Jan 6, 2025 · 1 comment · May be fixed by #5494
Open

Unused template parameter in model template #5488

chunyu3 opened this issue Jan 6, 2025 · 1 comment · May be fixed by #5494
Labels
ide Issues for VS, VSCode, Monaco, etc.
Milestone

Comments

@chunyu3
Copy link
Contributor

chunyu3 commented Jan 6, 2025

No diagnostic is issues for a templated model with a template parameter that is not used.

For example:

model Response<S, B> {
  @doc("The status code.")
  @statusCode
  _: S;
}

model Cat {
  meow: int32;
}

@route("/")
namespace root {
  op read(): Response<200, Cat>;
}
@chunyu3 chunyu3 changed the title Unused template parameter in model Unused template parameter in model template Jan 6, 2025
@RodgeFu RodgeFu added the ide Issues for VS, VSCode, Monaco, etc. label Jan 8, 2025
@markcowl markcowl added design:needed A design request has been raised that needs a proposal compiler:core Issues for @typespec/compiler and removed ide Issues for VS, VSCode, Monaco, etc. labels Jan 8, 2025
@markcowl markcowl added this to the Backlog milestone Jan 8, 2025
@chunyu3 chunyu3 added ide Issues for VS, VSCode, Monaco, etc. and removed design:needed A design request has been raised that needs a proposal triaged:core compiler:core Issues for @typespec/compiler labels Jan 8, 2025
@chunyu3
Copy link
Contributor Author

chunyu3 commented Jan 8, 2025

This issue is a sub-task of #181 which is a feature of typespec authoring in VSCode extension.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ide Issues for VS, VSCode, Monaco, etc.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants