Original issue: Azure/typespec-azure#2598
Playground
@versioned(MyVersions)
namespace MyLib {
enum MyVersions {
v1: "1",
v2: "2",
}
// Correctly throws an error
model MyFoo extends VersionedLib.Foo {};
// All of these should trigger the error that @useDependency is required!
model MyFoo is VersionedLib.Foo;
alias MyFooAlias = VersionedLib.Foo;
op FooOp is VersionedLib.FooOperation<{name: string}, string>;
alias FooOperationAlias<TParam, TResponse> = VersionedLib.FooOperation<TParam, TResponse>;
}
It seems clear to me in this instances that if your library is using "is" or aliasing things from a versioned library, then you are taking a dependency on the source library, but existing logic does not pick that up.
Original issue: Azure/typespec-azure#2598
Playground
It seems clear to me in this instances that if your library is using "is" or aliasing things from a versioned library, then you are taking a dependency on the source library, but existing logic does not pick that up.