forked from JuliaLang/julia
-
Notifications
You must be signed in to change notification settings - Fork 0
/
types.dot
82 lines (65 loc) · 1.96 KB
/
types.dot
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
digraph Types {
node [shape=box, style=dashed, color=gray]
Int [label="Int[`I]"]
Float [label="Float[`F]"]
Real [label="Real[`R]"]
Numeric [label="Numeric[`N]"]
Scalar [label="Scalar[`S]"]
Any [label="Any[`A]"]
node [style=solid]
Complex [label="Complex[`C]"]
Quaternion [label="Quaternion[`Q]"]
Rational [label="Rational[`T]"]
Function [label="Function[`F]"]
List [label="List[`L]"]
node [color=black]
edge [dir=none]
subgraph Scalars {
subgraph Numerics {
subgraph Reals {
subgraph Ints {
Int1 -> Int [label="I=Int1"]
Int8 -> Int [label="I=Int8"]
Int16 -> Int [label="I=Int16"]
Int32 -> Int [label="I=Int32"]
Int64 -> Int [label="I=Int64"]
Int128 -> Int [label="I=Int128"]
}
subgraph Floats {
Float32 -> Float [label="F=Float32"]
Float64 -> Float [label="F=Float64"]
Float128 -> Float [label="F=Float128"]
}
Int -> Real [label="R=Int[`I]"]
Float -> Real [label="R=Float[`F]"]
Rational -> Real [label="R=Rational[`T]"]
}
Real -> Numeric [label="N=Real[`R]"]
Complex -> Numeric [label="N=Complex[`C]"]
Quaternion -> Numeric [label="N=Quaternion[`Q]"]
}
Numeric -> Scalar [label="S=Numeric[`N]"]
String -> Scalar [label="S=String"]
Symbol -> Scalar [label="S=Symbol"]
}
Function -> Any [label="A=Function[`F]"]
Scalar -> Any [label="A=Scalar[`S]"]
List -> Any [label="A=List[`L]"]
/* lossless conversions */
edge [dir=forward, constraint=false, style=dashed]
Int1 -> Int8
Int8 -> Int16
Int16 -> Int32
Int32 -> Int64
Int64 -> Int128
Float32 -> Float64
Float64 -> Float128
Int16 -> Float32
Int32 -> Float64
Int64 -> Float128
Real -> Complex [label="C=R"]
Complex -> Quaternion [label="Q=C"]
/* lossy conversion */
edge [style=dotted]
Rational -> Float
}