()
| 249 | } |
| 250 | |
| 251 | format() { |
| 252 | const content = DOM.span({textContent: this.line + '\n'}); |
| 253 | let formattedCode = content.innerHTML.split(kRegisterSplitRegexp) |
| 254 | .map(part => this._formatRegisterPart(part)) |
| 255 | .join(''); |
| 256 | formattedCode = |
| 257 | formattedCode.split(kAnyAddressRegexp) |
| 258 | .map((part, index) => this._formatAddressPart(part, index)) |
| 259 | .join(''); |
| 260 | // Let's replace the base-address since it doesn't add any value. |
| 261 | // TODO |
| 262 | content.innerHTML = formattedCode; |
| 263 | return content; |
| 264 | } |
| 265 | |
| 266 | _formatRegisterPart(part) { |
| 267 | if (!kIsRegisterRegexp.test(part)) return part; |
nothing calls this directly
no test coverage detected