Tags: umbreak/sorbet
Tags
Non-mutating version of `resolveConstants` (sorbet#5532) * Move computeLinearization to GlobalState * pre-work: Use lambda for better clang-format * computeLinearization in GlobalState::initEmpty This should be safe--if we ever call addMixin after this, we will reset the linearization status on that class. This allows us to call `verifyLinearizationComputed` in `runIncrementalBestEffort` (because our test suite tests an edge case where we run `runIncrementalBestEffort` with `--no-stdlib` so Resolver truly has never been run before). * Non-mutating version of `resolveConstants` Mostly uses the technique that froydnj established in sorbet#5456. * Rest of the failures * Also run infer
Add T::Enumerator::Lazy (requires static and runtime bump!) (sorbet#5552 ) Fixes sorbet#3028
Drop procs.rbi file back to true (sorbet#5554)
Change the printing in procs.rbi (sorbet#5525) * Change the printing in procs.rbi Just happened to look at it, and got nerd snipped by the formatting. * update test
Use callLocs in fewer error messages (sorbet#5551) * Add argsLoc helper, add an `initialize` autocorrect * Autocorrect to delete block if unneeded * Use funLoc for more errors This is important because otherwise if there happens to be a block, Sorbet will chunder a huge red line over the whole method call including the block arg if present, which sometimes just makes half the file turn red. * Use argLocs for "Not enough arguments" * Change error location for `T.must` * Change location for missing required kwarg * Change location for required block error * Change error message for type parameter arity
Insert `extend T::Sig` when missing (sorbet#5546) Fixes sorbet#5242
Revert "Defer sorting resolver todo lists until it matters (sorbet#5527… …)" (sorbet#5553) This reverts commit 87fe72d.
Improve "Too many arguments" error message (sorbet#5544) * pre-work: Test autocorrects in test/cli/arity-messages * Improve "Too many arguments" error message - Shows the red squiggle on the extra args, not the whole method call (and definitely not on any block that is present). - Adds an autocorrect that can be run to delete the extra args (useful for things like codemods that remove args from methods). * wip even better * Add another test * Fix existing tests * whoops, left a TODO in * Add another test * Prefix tests with `autocorrect_`
Bump VSCode extension (sorbet#5542) 0.3.12 -> 0.3.13
make `TypePtr` parameter passing more idiomatic in `TypeErrorDiagnost… …ics` (sorbet#5540)
PreviousNext