NCAR / micm

A model-independent chemistry module for atmosphere models
https://ncar.github.io/micm/
Apache License 2.0
6 stars 4 forks source link

Need a test for movement assignment and constructor #458

Closed sjsprecious closed 3 months ago

sjsprecious commented 4 months ago

While working on the PR #452 , Matt discovered that in the movement assignment and constructor, we needed to manually reset other.param_.d_data_ = nullptr after the move operator. Otherwise, the cudaFree will be performed twice for the same device data and an error will be triggered later.

It will be better to add a test for this so that we won't be trapped by this again.