-
Notifications
You must be signed in to change notification settings - Fork 171
Fix tuple arguments type in function #1349
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
src/libasr/codegen/asr_to_llvm.cpp
Outdated
@@ -2984,7 +2984,8 @@ class ASRToLLVMVisitor : public ASR::BaseVisitor<ASRToLLVMVisitor> | |||
ASR::storage_typeType local_m_storage = ASR::storage_typeType::Default; | |||
llvm_el_types.push_back(get_arg_type_from_ttype_t(asr_tuple->m_type[i], m_abi, | |||
arg_m_abi, local_m_storage, arg_m_value_attr, local_n_dims, | |||
local_a_kind, is_local_array_type, ASRUtils::intent_local)); | |||
local_a_kind, is_local_array_type, | |||
ASRUtils::intent_local)->getPointerElementType()); |
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.
You can't use getPointerElementType
(not allowed from LLVM 15 onwards). So please figure out a different way to achieve the same goal that you are trying to by using this API.
src/libasr/codegen/asr_to_llvm.cpp
Outdated
arg_m_abi, local_m_storage, arg_m_value_attr, local_n_dims, | ||
local_a_kind, is_local_array_type, | ||
ASRUtils::intent_local)->getPointerElementType()); | ||
llvm_el_types.push_back(get_type_from_ttype_t(asr_tuple->m_type[i], |
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.
You can use get_type_from_ttype_t_util
as well. It won't require you to declare auxiliary argument variables.
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.
Thanks! Updated
What is the status of this? @czgdp1807 can you please review? |
Already reviewed. See #1349 (comment). Waiting for @Smit-create to update. |
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.
Looks great, a simple change.
Fixes #1348