Explicitly set dimension to be nullptr when empty vector

An empty std::vector is allowed to have any value for the
std::vector::data (pointer) field. When a std::vector is
transferred into ANeuralNetworksOperandType::dimensionCount
and ANeuralNetworksOperandType::dimensions,
ANeuralNetworksOperandType::dimensions must be explicit set
to nullptr if the std::vector is empty.

This CL additionally has come code cleanup, such as removing the
now-unused setFromIntList utility function.

Bug: 76122637
Test: mma
Test: NeuralNetworksTest
Change-Id: I097464df78ee037fd87bc8a970f696d5d3bb6e3e
4 files changed
tree: dc40ac24bafa5607e99c60d8eee6e32529ec3fe2
  1. nn/
  2. OWNERS