It appears that all of the following can have their invariants broken by projection.

Parents

  • EnumMember.enum
  • ModelProperty.model
  • Operation.interface
  • UnionVariant.union

SourceProperty

  • ModelProperty.sourceProperty

When fixing this, you should be able to make the simplification described in isImplicitPathParam in parameters.ts:

https://github.com/microsoft/cadl/blob/aee5025f5de10bd9b866e7437a806eb1431aeba4/packages/rest/src/http/parameters.ts#L60-L62

and revert what I think was another workaround for this in #819:

https://github.com/microsoft/cadl/pull/819/files#diff-96a2a8924df0be7c47132dbeb88359876840b1300e4c985e5865fe709dee764b

0
© 2022 pullanswer.com - All rights reserved.