...

Source file src/github.com/mitchellh/copystructure/copier_time.go

Documentation: github.com/mitchellh/copystructure

     1  package copystructure
     2  
     3  import (
     4  	"reflect"
     5  	"time"
     6  )
     7  
     8  func init() {
     9  	Copiers[reflect.TypeOf(time.Time{})] = timeCopier
    10  }
    11  
    12  func timeCopier(v interface{}) (interface{}, error) {
    13  	// Just... copy it.
    14  	return v.(time.Time), nil
    15  }
    16  

View as plain text