Skip to content

Commit 638b47a

Browse files
committed
DEV: Add kind argument while calling shape intrinsic in ArrayBroadcast
1 parent c4b6875 commit 638b47a

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/libasr/asr_utils.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ void update_call_args(Allocator &al, SymbolTable *current_scope, bool implicit_i
190190
}
191191
return sym;
192192
}
193-
193+
194194
void handle_Var(ASR::expr_t* arg_expr, ASR::expr_t** expr_to_replace) {
195195
if (ASR::is_a<ASR::Var_t>(*arg_expr)) {
196196
ASR::Var_t* arg_var = ASR::down_cast<ASR::Var_t>(arg_expr);
@@ -1461,8 +1461,10 @@ void make_ArrayBroadcast_t_util(Allocator& al, const Location& loc,
14611461
size_t expr1_ndims) {
14621462
ASR::ttype_t* expr1_type = ASRUtils::expr_type(expr1);
14631463
Vec<ASR::expr_t*> shape_args;
1464-
shape_args.reserve(al, 1);
1464+
shape_args.reserve(al, 2);
14651465
shape_args.push_back(al, expr1);
1466+
shape_args.push_back(al,
1467+
make_ConstantWithKind(make_IntegerConstant_t, make_Integer_t, 4, 4, loc));
14661468

14671469
Vec<ASR::dimension_t> dims;
14681470
dims.reserve(al, 1);

0 commit comments

Comments
 (0)