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

modelValuesAccessorVector setup template matches modelValues #1422

Closed danielturek closed 5 months ago

danielturek commented 7 months ago

@perrydv as best I see this fixes a small typo in the modelValuesAccessorVector_setupCodeTemplate, which defines the setup code for copy operations to/from modelValues objects.  I believe this was a harmless partial matching, which as-written matches the correct modelValues object because of the same prefix "model".  This PR corrects the partial match typo, and also enforces exact matching by now using LIST[["VAR"]] syntax.

That said, @perrydv you should definitely look at this, and confirm this makes sense.

danielturek commented 6 months ago

@perrydv @paciorek Pending testing, I think this is ok for review, and merging into devel.

danielturek commented 6 months ago

Testing passed, I'm ok with this being merged in, pending any additional review.

paciorek commented 5 months ago

@perrydv just wanted to check with you on this before merging.

perrydv commented 5 months ago

Yes, LGTM. Thanks @danielturek for tracking this down.