mirror of
https://github.com/vercel-labs/scriptc.git
synced 2026-11-02 07:43:42 +08:00
An async method in an object literal with no return annotation and a contextual signature inferred its own (narrower) literal type, while its `return` literal was built at the contextually typed record: the return statement then had to convert the wider record into the narrower literal, which fails with SC2002. The method now takes its return type from the contextual property's call signature, as the arrow form does. Sync methods are unchanged; they already adopt their slot. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>