Descriptiontext/template: implement comparison of basic types
Add eq, lt, etc. to allow one to do simple comparisons.
It's basic types only (booleans, integers, unsigned integers,
floats, complex, string) because that's easy, easy to define,
and covers the great majority of useful cases, while leaving
open the possibility of a more sweeping definition later.
{{if eq .X .Y}}X and Y are equal{{else}}X and Y are unequal{{end}}
Patch Set 1 #
Total comments: 3
Patch Set 2 : diff -r 5b772b490972 https://code.google.com/p/go/ #Patch Set 3 : diff -r 5b772b490972 https://code.google.com/p/go/ #Patch Set 4 : diff -r 5b772b490972 https://code.google.com/p/go/ #Patch Set 5 : diff -r 79e4edb2a8fc https://code.google.com/p/go/ #
MessagesTotal messages: 9
|