| 1570 | |
| 1571 | |
| 1572 | static int union_l (lua_State *L) { |
| 1573 | int l1, l2; |
| 1574 | int size = 0; |
| 1575 | Instruction *p1 = getpatt(L, 1, &l1); |
| 1576 | Instruction *p2 = getpatt(L, 2, &l2); |
| 1577 | CharsetTag st2; |
| 1578 | if (isfail(p1)) /* check for simple identities */ |
| 1579 | lua_pushvalue(L, 2); /* fail / a == a */ |
| 1580 | else if (isfail(p2) || issucc(p1)) |
| 1581 | lua_pushvalue(L, 1); /* a / fail == a; true / a == true */ |
| 1582 | else { |
| 1583 | tocharset(p2, &st2); |
| 1584 | separateparts(L, p1, l1, l2, &size, &st2); |
| 1585 | } |
| 1586 | return 1; |
| 1587 | } |
| 1588 | |
| 1589 | |
| 1590 | static int repeatcharset (lua_State *L, Charset cs, int l1, int n) { |
nothing calls this directly
no test coverage detected