-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Fix #3248: Handle repeated arguments in results of unapply selectors #3747
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
Conversation
…tors Normal unapply selectors can return results that have a repeated argument as last element. This needs to be handled. This also subsumes the previous way to express such arguments with `unapplySeq`. In the long run, we should be able to do without `unapplySeq` altogether. This is an intermediate step to get there.
This currently fails the exhaustivity checks. @liufengyun Can you see whether this is fixable? |
@odersky : The bug is fixed. There are 3 problems:
|
@liufengyun Looks good. Thanks for the fix! |
This PR improved the performance of the compiler in http://dotty-bench.epfl.ch/. |
Wow! I looked at the changes and have no idea what could have caused this. Maybe Fengyun's changes to the pattern matcher? |
It's related to the machine restart, where Turbo Disable setting failed. The machine powered off around Jan 10th for unknown causes. Today I restarted machine, ran the config to fixed the CPU frequency and disable Turbo. For some reason, the Turbo mode setting doesn't take effect. I'll fix the setting and rerun the benchmarks for the last 2-3 merges. |
I'm tagging this PR with a "needs spec" as it affects what's written here. |
@OlivierBlanvillain I would open a new issue instead. It will probably get lost othwerwise |
cannot be written explicitly.
cannot be written explicitly.
cannot be written explicitly.
Normal unapply selectors can return results that have a repeated
argument as last element. This needs to be handled. This also subsumes
the previous way to express such arguments with
unapplySeq
.In the long run, we should be able to do without
unapplySeq
altogether.This is an intermediate step to get there.