-
Notifications
You must be signed in to change notification settings - Fork 156
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
Fix non-exhaustive warnings with the Ast.expr.Call node #227
Open
Mingun
wants to merge
1
commit into
kaitai-io:master
Choose a base branch
from
Mingun:fix-warns-call-node
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Mingun
force-pushed
the
fix-warns-call-node
branch
from
December 21, 2020 09:44
95adee9
to
3f66677
Compare
Mingun
force-pushed
the
fix-warns-call-node
branch
from
May 12, 2021 15:53
3f66677
to
b41de90
Compare
Mingun
force-pushed
the
fix-warns-call-node
branch
from
August 25, 2021 08:09
b41de90
to
6667717
Compare
Mingun
force-pushed
the
fix-warns-call-node
branch
from
April 10, 2023 16:00
6667717
to
efb528c
Compare
Mingun
force-pushed
the
fix-warns-call-node
branch
from
September 12, 2023 14:14
efb528c
to
299ee3a
Compare
Mingun
force-pushed
the
fix-warns-call-node
branch
2 times, most recently
from
October 24, 2023 15:28
1fd61b1
to
5c13cf7
Compare
Mingun
force-pushed
the
fix-warns-call-node
branch
from
March 8, 2024 06:06
5c13cf7
to
ea3fcf0
Compare
@GreyCat, @generalmimon, I see that you have some activity in the project recently. Could you find a time to review my PRs, for example, this? |
Mingun
force-pushed
the
fix-warns-call-node
branch
3 times, most recently
from
March 11, 2024 16:04
e3f7ced
to
d448244
Compare
Mingun
force-pushed
the
fix-warns-call-node
branch
from
April 6, 2024 12:03
d448244
to
9a303bd
Compare
Mingun
added a commit
to Mingun/ksc-rs
that referenced
this pull request
Jul 7, 2024
Currently original KSC can parse more wider range of call expressions then it can handle, actually it can handle only `[expr.]$name($args)` construction, but it can parse, for example: - ()(args) - [](args) - 42(args) - ""(args) - true(args) This is fixed in the original compiler in the kaitai-io/kaitai_struct_compiler#227 but it still not merged
Mingun
added a commit
to Mingun/ksc-rs
that referenced
this pull request
Jul 7, 2024
Currently original KSC can parse more wider range of call expressions then it can handle, actually it can handle only `[expr.]$name($args)` construction, but it can parse, for example: - ()(args) - [](args) - 42(args) - ""(args) - true(args) This is fixed in the original compiler in the kaitai-io/kaitai_struct_compiler#227 but it still not merged
Mingun
force-pushed
the
fix-warns-call-node
branch
from
July 13, 2024 15:54
9a303bd
to
a0914b4
Compare
Mingun
added a commit
to Mingun/ksc-rs
that referenced
this pull request
Jul 13, 2024
Currently original KSC can parse more wider range of call expressions then it can handle, actually it can handle only `[expr.]$name($args)` construction, but it can parse, for example: - ()(args) - [](args) - 42(args) - ""(args) - true(args) This is fixed in the original compiler in the kaitai-io/kaitai_struct_compiler#227 but it still not merged
Mingun
force-pushed
the
fix-warns-call-node
branch
from
July 16, 2024 14:22
a0914b4
to
db77b64
Compare
Mingun
added a commit
to Mingun/ksc-rs
that referenced
this pull request
Jul 28, 2024
Currently original KSC can parse more wider range of call expressions then it can handle, actually it can handle only `[expr.]$name($args)` construction, but it can parse, for example: - ()(args) - [](args) - 42(args) - ""(args) - true(args) This is fixed in the original compiler in the kaitai-io/kaitai_struct_compiler#227 but it still not merged
Mingun
added a commit
to Mingun/ksc-rs
that referenced
this pull request
Aug 8, 2024
Currently original KSC can parse more wider range of call expressions then it can handle, actually it can handle only `[expr.]$name($args)` construction, but it can parse, for example: - ()(args) - [](args) - 42(args) - ""(args) - true(args) This is fixed in the original compiler in the kaitai-io/kaitai_struct_compiler#227 but it still not merged
Mingun
added a commit
to Mingun/ksc-rs
that referenced
this pull request
Aug 9, 2024
Currently original KSC can parse more wider range of call expressions then it can handle, actually it can handle only `[expr.]$name($args)` construction, but it can parse, for example: - ()(args) - [](args) - 42(args) - ""(args) - true(args) This is fixed in the original compiler in the kaitai-io/kaitai_struct_compiler#227 but it still not merged
Mingun
added a commit
to Mingun/ksc-rs
that referenced
this pull request
Aug 14, 2024
Currently original KSC can parse more wider range of call expressions then it can handle, actually it can handle only `[expr.]$name($args)` construction, but it can parse, for example: - ()(args) - [](args) - 42(args) - ""(args) - true(args) This is fixed in the original compiler in the kaitai-io/kaitai_struct_compiler#227 but it still not merged
Because function pointers is forbidden in the expression language from now parser won't allow anymore following constructions: - 42() - "string"() - true() - (...)() - []() Fixes the warnings (3): ``` [warn] /home/runner/work/kaitai_struct_compiler/kaitai_struct_compiler/compiler/shared/src/main/scala/io/kaitai/struct/GraphvizClassCompiler.scala:319:24: Exhaustivity analysis reached max recursion depth, not all missing cases are reported. [warn] (Please try with scalac -Ypatmat-exhaust-depth 40 or -Ypatmat-exhaust-depth off.) [warn] val fromFunc = func match { [warn] ^ [warn] /home/runner/work/kaitai_struct_compiler/kaitai_struct_compiler/compiler/shared/src/main/scala/io/kaitai/struct/GraphvizClassCompiler.scala:319:24: Exhaustivity analysis reached max recursion depth, not all missing cases are reported. [warn] (Please try with scalac -Ypatmat-exhaust-depth 40 or -Ypatmat-exhaust-depth off.) [warn] val fromFunc = func match { [warn] ^ [warn] /home/runner/work/kaitai_struct_compiler/kaitai_struct_compiler/compiler/shared/src/main/scala/io/kaitai/struct/translators/CommonMethods.scala:192:5: Exhaustivity analysis reached max recursion depth, not all missing cases are reported. [warn] (Please try with scalac -Ypatmat-exhaust-depth 40 or -Ypatmat-exhaust-depth off.) [warn] func match { [warn] ^ ```
Mingun
force-pushed
the
fix-warns-call-node
branch
from
September 8, 2024 04:53
db77b64
to
307b76b
Compare
Mingun
added a commit
to Mingun/ksc-rs
that referenced
this pull request
Oct 6, 2024
Currently original KSC can parse more wider range of call expressions then it can handle, actually it can handle only `[expr.]$name($args)` construction, but it can parse, for example: - ()(args) - [](args) - 42(args) - ""(args) - true(args) This is fixed in the original compiler in the kaitai-io/kaitai_struct_compiler#227 but it still not merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Because function pointers are forbidden in the expression language from now parser
won't allow anymore following constructions:
42()
"string"()
true()
(...)()
[]()
This PR fixes those warnings (3):
Strangely, but it seems that some code are compiled twice, because you can notice identical warnings, for example
GraphvizClassCompiler.scala:319:24
.Somehow it introduces 3 new warnings, but it seems that there have a limit on count of warnings from compiler (!?):