containers / virtcontainers

A Go package for building hardware virtualized container runtimes
Apache License 2.0
139 stars 43 forks source link

constification of constifiable vars #636

Closed egernst closed 6 years ago

egernst commented 6 years ago

Noticed that we pretty liberally use var ( ) for what could in many cases be treated as a const.
Example can be seen at https://github.com/containers/virtcontainers/blob/master/kata_agent.go#L38

Some of these are more explicitly marked as var since they are updated during unit tests (see *_test.go) to aid in testing. For the remainder it'd be a good idea to mark these as consts.

egernst commented 6 years ago

This issue was moved to kata-containers/runtime#142