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 crash when compiling is_list/1 call #7518
Fix crash when compiling is_list/1 call #7518
Conversation
CT Test Results 2 files 296 suites 13m 19s ⏱️ Results for commit f9a3fa9. ♻️ This comment has been updated with latest results. To speed up review, make sure that you have read Contributing to Erlang/OTP and that all checks pass. See the TESTING and DEVELOPMENT HowTo guides for details about how to run test locally. Artifacts
// Erlang/OTP Github Action Bot |
2764673
to
7f94589
Compare
7f94589
to
f9a3fa9
Compare
%% This instruction was a call to is_list/1, which was | ||
%% rewritten to an is_nonempty_list test by | ||
%% beam_ssa_type. BEAM has no is_nonempty_list instruction | ||
%% that will return a boolean, so we must revert it to an | ||
%% is_list/1 call. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Given the relative rarity of needing boolean values from type tests, I wonder if it wouldn't be better to convert them at an early stage from A = is_xyz(X)
to something like A = if is_xyz(X) -> true; not is_xyz(X) -> false end
(it would also simplify some of the work I'm doing 😄).
Fixes #7504