| 188 | } |
| 189 | |
| 190 | txSlot* fxNewRegExpInstance(txMachine* the) |
| 191 | { |
| 192 | #if mxRegExp |
| 193 | txSlot* instance; |
| 194 | txSlot* property; |
| 195 | instance = fxNewObjectInstance(the); |
| 196 | |
| 197 | property = instance->next = fxNewSlot(the); |
| 198 | property->flag = XS_INTERNAL_FLAG; |
| 199 | property->kind = XS_REGEXP_KIND; |
| 200 | property->value.regexp.code = C_NULL; |
| 201 | property->value.regexp.data = C_NULL; |
| 202 | |
| 203 | property = property->next = fxNewSlot(the); |
| 204 | property->flag = XS_INTERNAL_FLAG; |
| 205 | property->kind = (mxEmptyString.kind == XS_STRING_X_KIND) ? XS_KEY_X_KIND : XS_KEY_KIND; |
| 206 | property->value.key.string = mxEmptyString.value.string; |
| 207 | property->value.key.sum = 0; |
| 208 | |
| 209 | property = fxNextIntegerProperty(the, property, 0, mxID(_lastIndex), XS_DONT_DELETE_FLAG | XS_DONT_ENUM_FLAG); |
| 210 | |
| 211 | return instance; |
| 212 | #else |
| 213 | return NULL; |
| 214 | #endif |
| 215 | } |
| 216 | |
| 217 | void fx_RegExp(txMachine* the) |
| 218 | { |
no test coverage detected