migueldeicaza / TensorFlowSharp

TensorFlow API for .NET languages
MIT License
3.14k stars 578 forks source link

TFDisposable disposes handle on assignment #461

Closed EnricoMi closed 4 years ago

EnricoMi commented 4 years ago

TFTensor.Handle is already assignable, but the current pointer has to be disposed first. This ensures that the current pointer gets disposed on assignment.