[gridwriter] Fix return type in forwarding function
This makes the function work for std::vector. T is bool but values[0] returns (non-standard-compliant in some impl.) some proxy reference class even if the container is const. Explicitly converting to T works. Thed default return type would be auto which also returns by value.