(self, other)
| 100 | self.tokenization = self.tokenization[:idx] + other.tokenization + self.tokenization[idx:] |
| 101 | |
| 102 | def append(self, other): |
| 103 | if isinstance(other, (CommandToken, TypeToken)): |
| 104 | self.tokenization.append(other.Id) |
| 105 | self.text += other.token |
| 106 | self.original_text += other.token |
| 107 | elif isinstance(other, Tokenization): |
| 108 | self.tokenization.extend(other.tokenization) |
| 109 | self.text += other.text |
| 110 | self.original_text += other.original_text |
| 111 | else: |
| 112 | self.tokenization.append(other) |
| 113 | return self |
| 114 | |
| 115 | def extend(self, other): |
| 116 | if isinstance(other, (CommandToken, TypeToken)): |
no test coverage detected