Julia can be launched with --check-bounds={yes|no|auto} to emit bounds checks always, never, or respect @inbounds declarations.
The default is auto, but currently we override it to yes everywhere, mainly to improve compiled code re-use, and hence reduce CI time.
#2336 was fixed by #2345.
It works, but is complex, adds a lot of boilerplate, and you have to remember adding --check-bounds=yes each time you run Julia, since you cannot set it with an ENV variable. It also goes against the default Julia behavior, which, starting from 1.13 with JuliaLang/Pkg.jl#4494 is actually going the other way, to use the default more often.
Perhaps it is an idea to add a weekly Ribasim test run on TeamCity with bounds checking forced to true.
The default is auto, but currently we override it to yes everywhere, mainly to improve compiled code re-use, and hence reduce CI time.
#2336 was fixed by #2345.
It works, but is complex, adds a lot of boilerplate, and you have to remember adding
--check-bounds=yeseach time you run Julia, since you cannot set it with an ENV variable. It also goes against the default Julia behavior, which, starting from 1.13 with JuliaLang/Pkg.jl#4494 is actually going the other way, to use the default more often.Perhaps it is an idea to add a weekly Ribasim test run on TeamCity with bounds checking forced to true.