| 166 | const char *getName() HXCPP_OVERRIDE { return gArrayFuncNames[FUNC]; } |
| 167 | |
| 168 | int runInt(CppiaCtx *ctx) HXCPP_OVERRIDE |
| 169 | { |
| 170 | if (FUNC==afPush) |
| 171 | { |
| 172 | ArrayAnyImpl *thisVal = (ArrayAnyImpl *)thisExpr->runObject(ctx); |
| 173 | BCR_CHECK; |
| 174 | hx::Object * val = args[0]->runObject(ctx); |
| 175 | BCR_CHECK; |
| 176 | return thisVal->CALL(push)(Dynamic(val)); |
| 177 | } |
| 178 | if (FUNC==afContains) |
| 179 | { |
| 180 | ArrayAnyImpl *thisVal = (ArrayAnyImpl *)thisExpr->runObject(ctx); |
| 181 | BCR_CHECK; |
| 182 | hx::Object * val = args[0]->runObject(ctx); |
| 183 | BCR_CHECK; |
| 184 | return thisVal->CALL(contains)(val); |
| 185 | } |
| 186 | if (FUNC==afRemove) |
| 187 | { |
| 188 | ArrayAnyImpl *thisVal = (ArrayAnyImpl *)thisExpr->runObject(ctx); |
| 189 | BCR_CHECK; |
| 190 | hx::Object * val = args[0]->runObject(ctx); |
| 191 | BCR_CHECK; |
| 192 | return thisVal->CALL(remove)(val); |
| 193 | } |
| 194 | if (FUNC==afIndexOf) |
| 195 | { |
| 196 | ArrayAnyImpl *thisVal = (ArrayAnyImpl *)thisExpr->runObject(ctx); |
| 197 | BCR_CHECK; |
| 198 | Dynamic a0 = args[0]->runObject(ctx); |
| 199 | BCR_CHECK; |
| 200 | hx::Object *a1 = args[1]->runObject(ctx); |
| 201 | BCR_CHECK; |
| 202 | return thisVal->CALL(indexOf)( a0, a1 ); |
| 203 | } |
| 204 | if (FUNC==afLastIndexOf) |
| 205 | { |
| 206 | ArrayAnyImpl *thisVal = (ArrayAnyImpl *)thisExpr->runObject(ctx); |
| 207 | BCR_CHECK; |
| 208 | Dynamic a0 = args[0]->runObject(ctx); |
| 209 | BCR_CHECK; |
| 210 | hx::Object *a1 = args[1]->runObject(ctx); |
| 211 | BCR_CHECK; |
| 212 | return thisVal->CALL(lastIndexOf)( a0, a1 ); |
| 213 | } |
| 214 | |
| 215 | return Dynamic( runObject(ctx) ); |
| 216 | } |
| 217 | |
| 218 | Float runFloat(CppiaCtx *ctx) HXCPP_OVERRIDE |
| 219 | { |