Source file
test/rune.go
1
2
3
4
5
6
7
8
9
10 package rune
11
12 var (
13 r0 = 'a'
14 r1 = 'a'+1
15 r2 = 1+'a'
16 r3 = 'a'*2
17 r4 = 'a'/2
18 r5 = 'a'<<1
19 r6 = 'b'<<2
20 r7 int32
21
22 r = []rune{r0, r1, r2, r3, r4, r5, r6, r7}
23 )
24
25 var (
26 f0 = 1.2
27 f1 = 1.2/'a'
28
29 f = []float64{f0, f1}
30 )
31
32 var (
33 i0 = 1
34 i1 = 1<<'\x01'
35
36 i = []int{i0, i1}
37 )
38
39 const (
40 maxRune = '\U0010FFFF'
41 )
42
43 var (
44 b0 = maxRune < r0
45
46 b = []bool{b0}
47 )
48
View as plain text