github.com/graybobo/golang.org-package-offline-cache@v0.0.0-20200626051047-6608995c132f/x/blog/content/constants/float1.go (about)

     1  // +build OMIT
     2  
     3  package main
     4  
     5  import "fmt"
     6  
     7  func main() {
     8  	// START OMIT
     9  	type MyFloat64 float64
    10  	const Zero = 0.0
    11  	const TypedZero float64 = 0.0
    12  	var mf MyFloat64
    13  	mf = 0.0       // OK
    14  	mf = Zero      // OK
    15  	mf = TypedZero // Bad
    16  	fmt.Println(mf)
    17  	// STOP OMIT
    18  }