annotate dmd/CmpExp.d @ 0:10317f0c89a5

Initial commit
author korDen
date Sat, 24 Oct 2009 08:42:06 +0400
parents
children cab4c37afb89
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
1 module dmd.CmpExp;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
2
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
3 import dmd.Expression;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
4 import dmd.Identifier;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
5 import dmd.backend.elem;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
6 import dmd.InterState;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
7 import dmd.Loc;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
8 import dmd.TOK;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
9 import dmd.Scope;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
10 import dmd.IRState;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
11 import dmd.Type;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
12 import dmd.Id;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
13 import dmd.TY;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
14 import dmd.ErrorExp;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
15 import dmd.IntegerExp;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
16 import dmd.MATCH;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
17 import dmd.BinExp;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
18 import dmd.WANT;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
19 import dmd.GlobalExpressions;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
20
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
21 import dmd.expression.Util;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
22 import dmd.codegen.Util;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
23 import dmd.expression.Cmp;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
24
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
25 import dmd.backend.Util;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
26 import dmd.backend.RTLSYM;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
27 import dmd.backend.TYM;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
28 import dmd.backend.OPER;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
29 import dmd.backend.rel;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
30
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
31 class CmpExp : BinExp
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
32 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
33 this(TOK op, Loc loc, Expression e1, Expression e2)
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
34 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
35 super(loc, op, CmpExp.sizeof, e1, e2);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
36 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
37
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
38 Expression semantic(Scope sc)
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
39 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
40 Expression e;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
41 Type t1;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
42 Type t2;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
43
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
44 version (LOGSEMANTIC) {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
45 printf("CmpExp.semantic('%s')\n", toChars());
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
46 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
47 if (type)
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
48 return this;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
49
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
50 BinExp.semanticp(sc);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
51
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
52 if (e1.type.toBasetype().ty == Tclass && e2.op == TOKnull ||
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
53 e2.type.toBasetype().ty == Tclass && e1.op == TOKnull)
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
54 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
55 error("do not use null when comparing class types");
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
56 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
57
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
58 e = op_overload(sc);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
59 if (e)
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
60 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
61 if (!e.type.isscalar() && e.type.equals(e1.type))
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
62 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
63 error("recursive opCmp expansion");
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
64 e = new ErrorExp();
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
65 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
66 else
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
67 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
68 e = new CmpExp(op, loc, e, new IntegerExp(loc, 0, Type.tint32));
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
69 e = e.semantic(sc);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
70 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
71 return e;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
72 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
73
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
74 typeCombine(sc);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
75 type = Type.tboolean;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
76
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
77 // Special handling for array comparisons
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
78 t1 = e1.type.toBasetype();
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
79 t2 = e2.type.toBasetype();
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
80 if ((t1.ty == Tarray || t1.ty == Tsarray || t1.ty == Tpointer) &&
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
81 (t2.ty == Tarray || t2.ty == Tsarray || t2.ty == Tpointer))
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
82 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
83 if (t1.nextOf().implicitConvTo(t2.nextOf()) < MATCHconst &&
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
84 t2.nextOf().implicitConvTo(t1.nextOf()) < MATCHconst &&
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
85 (t1.nextOf().ty != Tvoid && t2.nextOf().ty != Tvoid))
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
86 error("array comparison type mismatch, %s vs %s", t1.nextOf().toChars(), t2.nextOf().toChars());
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
87 e = this;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
88 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
89 else if (t1.ty == Tstruct || t2.ty == Tstruct ||
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
90 (t1.ty == Tclass && t2.ty == Tclass))
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
91 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
92 if (t2.ty == Tstruct)
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
93 error("need member function opCmp() for %s %s to compare", t2.toDsymbol(sc).kind(), t2.toChars());
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
94 else
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
95 error("need member function opCmp() for %s %s to compare", t1.toDsymbol(sc).kind(), t1.toChars());
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
96 e = this;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
97 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
98 /// static if (true) {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
99 else if (t1.iscomplex() || t2.iscomplex())
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
100 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
101 error("compare not defined for complex operands");
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
102 e = new ErrorExp();
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
103 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
104 /// }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
105 else
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
106 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
107 e1.rvalue();
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
108 e2.rvalue();
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
109 e = this;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
110 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
111
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
112 //printf("CmpExp: %s, type = %s\n", e.toChars(), e.type.toChars());
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
113 return e;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
114 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
115
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
116 Expression optimize(int result)
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
117 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
118 Expression e;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
119
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
120 //printf("CmpExp::optimize() %s\n", toChars());
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
121 e1 = e1.optimize(WANTvalue | (result & WANTinterpret));
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
122 e2 = e2.optimize(WANTvalue | (result & WANTinterpret));
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
123
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
124 Expression e1 = fromConstInitializer(result, this.e1);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
125 Expression e2 = fromConstInitializer(result, this.e2);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
126
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
127 e = Cmp(op, type, e1, e2);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
128 if (e is EXP_CANT_INTERPRET)
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
129 e = this;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
130 return e;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
131 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
132
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
133 Expression interpret(InterState* istate)
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
134 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
135 assert(false);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
136 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
137
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
138 int isBit()
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
139 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
140 assert(false);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
141 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
142
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
143 bool isCommutative()
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
144 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
145 return true;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
146 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
147
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
148 Identifier opId()
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
149 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
150 return Id.cmp;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
151 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
152
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
153 elem* toElem(IRState* irs)
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
154 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
155 elem *e;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
156 OPER eop;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
157 Type t1 = e1.type.toBasetype();
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
158 Type t2 = e2.type.toBasetype();
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
159
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
160 switch (op)
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
161 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
162 case TOKlt: eop = OPlt; break;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
163 case TOKgt: eop = OPgt; break;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
164 case TOKle: eop = OPle; break;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
165 case TOKge: eop = OPge; break;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
166 case TOKequal: eop = OPeqeq; break;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
167 case TOKnotequal: eop = OPne; break;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
168
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
169 // NCEG floating point compares
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
170 case TOKunord: eop = OPunord; break;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
171 case TOKlg: eop = OPlg; break;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
172 case TOKleg: eop = OPleg; break;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
173 case TOKule: eop = OPule; break;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
174 case TOKul: eop = OPul; break;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
175 case TOKuge: eop = OPuge; break;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
176 case TOKug: eop = OPug; break;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
177 case TOKue: eop = OPue; break;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
178 default:
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
179 dump(0);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
180 assert(0);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
181 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
182 if (!t1.isfloating())
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
183 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
184 // Convert from floating point compare to equivalent
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
185 // integral compare
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
186 eop = cast(OPER)rel_integral(eop);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
187 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
188 if (cast(int)eop > 1 && t1.ty == Tclass && t2.ty == Tclass)
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
189 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
190 static if (true) {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
191 assert(0);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
192 } else {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
193 elem *ec1;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
194 elem *ec2;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
195
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
196 ec1 = e1.toElem(irs);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
197 ec2 = e2.toElem(irs);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
198 e = el_bin(OPcall,TYint,el_var(rtlsym[RTLSYM_OBJ_CMP]),el_param(ec1, ec2));
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
199 e = el_bin(eop, TYint, e, el_long(TYint, 0));
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
200 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
201 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
202 else if (cast(int)eop > 1 &&
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
203 (t1.ty == Tarray || t1.ty == Tsarray) &&
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
204 (t2.ty == Tarray || t2.ty == Tsarray))
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
205 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
206 elem* ea1;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
207 elem* ea2;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
208 elem* ep;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
209 Type telement = t1.nextOf().toBasetype();
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
210 int rtlfunc;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
211
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
212 ea1 = e1.toElem(irs);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
213 ea1 = array_toDarray(t1, ea1);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
214 ea2 = e2.toElem(irs);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
215 ea2 = array_toDarray(t2, ea2);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
216
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
217 version (DMDV2) {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
218 ep = el_params(telement.arrayOf().getInternalTypeInfo(null).toElem(irs),
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
219 ea2, ea1, null);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
220 rtlfunc = RTLSYM_ARRAYCMP2;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
221 } else {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
222 ep = el_params(telement.getInternalTypeInfo(null).toElem(irs), ea2, ea1, null);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
223 rtlfunc = RTLSYM_ARRAYCMP;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
224 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
225 e = el_bin(OPcall, TYint, el_var(rtlsym[rtlfunc]), ep);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
226 e = el_bin(eop, TYint, e, el_long(TYint, 0));
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
227 el_setLoc(e,loc);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
228 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
229 else
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
230 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
231 if (cast(int)eop <= 1)
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
232 {
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
233 /* The result is determinate, create:
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
234 * (e1 , e2) , eop
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
235 */
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
236 e = toElemBin(irs,OPcomma);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
237 e = el_bin(OPcomma,e.Ety,e,el_long(e.Ety,cast(int)eop));
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
238 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
239 else
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
240 e = toElemBin(irs,eop);
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
241 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
242 return e;
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
243 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
244 }
10317f0c89a5 Initial commit
korDen
parents:
diff changeset
245