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

MBS-11805 (I): Flow types and refactoring for guess case code (first half) #2182

Merged
merged 34 commits into from
Aug 9, 2021

Conversation

reosarevok
Copy link
Member

@reosarevok reosarevok commented Jul 23, 2021

Implement MBS-11805

The main goal of this is to add flow types to guess case, and fix any issues that surfaces, which I expect will be a bunch. Also fixing smaller eslint issues and whatnot as I see them.

@reosarevok reosarevok added the Refactoring Refactoring-only PRs (eslint fixes etc) label Jul 23, 2021
Context was missing a lot of stuff that is actually added to it later.
This expands it to support all those elements, but does not
(for now) rename resetContext, even though that only resets *part*
of the context.
@reosarevok reosarevok changed the title [WIP] Flow types and small refactorings for guess case code MBS-11805: [WIP] Flow types and small refactorings for guess case code Jul 23, 2021
gc is still not properly typed since that requires typing all of
Input, Output and the modes.

Clarify is, os, lc, uc to actual words.
@reosarevok reosarevok force-pushed the guess-case-refactoring branch 2 times, most recently from 647f963 to 568a80b Compare August 2, 2021 18:10
This is always applied in all our usages, so config.apply
is useless. Also, the return is never used, so this doesn't need
to return anything.
This will be needed for easy flow typing, plus flow no longer allows
this inside objects.
CFG_KEEP_UPPERCASED can probably change so keeping it writable for now.
@reosarevok reosarevok force-pushed the guess-case-refactoring branch 2 times, most recently from aaf73a8 to 1d0a7a2 Compare August 6, 2021 11:51
@reosarevok reosarevok changed the title MBS-11805: [WIP] Flow types and small refactorings for guess case code MBS-11805: [WIP] Flow types and refactoring for guess case code Aug 6, 2021
@metabrainz metabrainz deleted a comment from reosarevok Aug 6, 2021
@mwiencek mwiencek marked this pull request as ready for review August 6, 2021 17:16
@mwiencek mwiencek changed the title MBS-11805: [WIP] Flow types and refactoring for guess case code MBS-11805: Flow types and refactoring for guess case code Aug 6, 2021
gc.mode needs to be dropped to avoid recursion, but in any case,
it seems more sensible to just calculate it based on the currently
set modeName, rather than passing it around.
@reosarevok reosarevok changed the title MBS-11805: Flow types and refactoring for guess case code MBS-11805 (I): Flow types and refactoring for guess case code (first half) Aug 7, 2021
@mwiencek mwiencek merged commit b203ecf into metabrainz:master Aug 9, 2021
@reosarevok reosarevok deleted the guess-case-refactoring branch August 10, 2021 11:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Refactoring Refactoring-only PRs (eslint fixes etc)
Projects
None yet
2 participants