nimble-dev / nimble

The base NIMBLE package for R
http://R-nimble.org
BSD 3-Clause "New" or "Revised" License
156 stars 23 forks source link

detect invalid variable names in nfcode #1382

Closed paciorek closed 8 months ago

paciorek commented 9 months ago

Fixes #1335 , a longstanding issue that certain variable names conflict with C++ keywords but this is not error-trapped and C++ compilation fails.

paciorek commented 9 months ago

@perrydv would be good to have you give this a quick look before I merge.

perrydv commented 8 months ago

@paciorek I think this is ok. I can't think of a case where it would go haywire and do something unexpected. We could give it a nimbleOption toggle to be safe, but up to you.