TuringLang / JuliaBUGS.jl

A domain specific language (DSL) for probabilistic graphical models
https://turinglang.org/JuliaBUGS.jl/
MIT License
21 stars 3 forks source link

Improve error message when variable is used but not defined #213

Closed sunxd3 closed 1 month ago

sunxd3 commented 1 month ago

When a variable is referenced on the RHS, but not provided in data or appear on LHS, the compiler should error.

Previously, compile will error on these cases, but the error message can be cryptic -- usually in an array-out-of-bound type of errors.

This PR catches and reports these errors in a more graceful manner.

coveralls commented 1 month ago

Pull Request Test Coverage Report for Build 10900481812

Details


Changes Missing Coverage Covered Lines Changed/Added Lines %
src/compiler_pass.jl 35 38 92.11%
<!-- Total: 36 39 92.31% -->
Totals Coverage Status
Change from base Build 10881242099: 0.2%
Covered Lines: 1466
Relevant Lines: 1765

💛 - Coveralls