Skip to content

Commit

Permalink
DEV: Add an LCOMPILERS_ASSERT to make Array is actually of fixed size…
Browse files Browse the repository at this point in the history
… when physical type is FixedSizeArray
  • Loading branch information
czgdp1807 committed Sep 15, 2023
1 parent 39c0e90 commit b3127c8
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/libasr/codegen/llvm_utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1142,6 +1142,7 @@ namespace LCompilers {
break;
}
case ASR::array_physical_typeType::FixedSizeArray: {
LCOMPILERS_ASSERT(ASRUtils::is_fixed_size_array(v_type->m_dims, v_type->n_dims));
llvm_type = llvm::ArrayType::get(get_el_type(v_type->m_type, module),
ASRUtils::get_fixed_size_of_array(
v_type->m_dims, v_type->n_dims));
Expand Down

0 comments on commit b3127c8

Please sign in to comment.