CliMA / CliMA/ClimaCore.jl

inference failure when broadcasting over multiple structs and a Field

Open
#2,065 5 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
Julia
Stars
117
Forks
19
Avg merge
3d 4h
Merged PRs (30d)
41

Description

## Describe the bug
Reproducer added in #2062
Initially found in https://github.com/CliMA/ClimaLand.jl/pull/739

This is a type inference error that arises when a function is broadcast over one field and two structs that both have `broadcastable` extended using `tuple`. The types in the expression become too complex, and inference fails. The problem is simplified in the reproducer so the structs each contain one scalar value, and the called function itself does nothing. The reproducer was tested on fields constructed on multiple different spaces, and reproduced the bug on all of them.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.