Esteban Küber
2d7795dfb9
Be more accurate about calculating display_col
from a BytePos
...
No longer track "zero-width" chars in `SourceMap`, read directly from the line when calculating the `display_col` of a `BytePos`. Move `char_width` to `rustc_span` and use it from the emitter.
This change allows the following to properly align in terminals (depending on the font, the replaced control codepoints are rendered as 1 or 2 width, on my terminal they are rendered as 1, on VSCode text they are rendered as 2):
```
error: this file contains an unclosed delimiter
--> $DIR/issue-68629.rs:5:17
|
LL | ␜␟ts␀![{i
| -- unclosed delimiter
| |
| unclosed delimiter
LL | ␀␀ fn rݻoa>rݻm
| ^
```
2024-07-18 20:08:38 +00:00
..
2024-04-09 00:42:48 +02:00
2024-07-05 20:49:31 -04:00
2024-04-24 08:05:29 +00:00
2024-06-27 08:05:07 +02:00
2024-06-15 18:18:43 +02:00
2024-06-25 17:22:22 +02:00
2024-07-09 17:35:51 -03:00
2024-06-06 20:39:54 +00:00
2024-04-11 14:38:21 -04:00
2024-05-21 20:16:39 +00:00
2024-04-22 18:48:47 +02:00
2024-04-22 18:48:47 +02:00
2024-06-25 17:22:22 +02:00
2024-05-24 19:31:57 +08:00
2024-05-24 19:31:57 +08:00
2024-05-24 19:31:57 +08:00
2024-05-24 19:31:57 +08:00
2024-05-24 19:31:57 +08:00
2024-05-29 17:40:34 +08:00
2024-05-29 16:53:28 +08:00
2024-05-29 16:53:28 +08:00
2024-05-29 16:53:28 +08:00
2024-05-29 16:53:28 +08:00
2024-06-25 17:22:22 +02:00
2024-06-25 22:32:46 +02:00
2024-06-25 22:32:46 +02:00
2024-05-15 13:17:11 -05:00
2024-05-15 13:17:11 -05:00
2024-05-29 16:53:37 +08:00
2024-05-29 16:53:37 +08:00
2024-05-29 16:53:37 +08:00
2024-05-29 17:40:34 +08:00
2024-05-29 17:40:34 +08:00
2024-05-29 17:40:34 +08:00
2024-05-29 17:40:34 +08:00
2024-05-29 17:40:34 +08:00
2024-05-29 17:40:34 +08:00
2024-05-20 19:55:59 -07:00
2024-05-20 19:55:59 -07:00
2024-05-20 19:55:59 -07:00
2024-04-29 08:16:26 +05:30
2024-04-29 08:16:26 +05:30
2024-04-24 13:12:33 +01:00
2024-04-24 13:12:33 +01:00
2024-04-22 18:48:47 +02:00
2024-07-18 20:08:38 +00:00
2024-06-21 19:00:18 -04:00
2024-04-23 21:30:59 -07:00
2024-04-23 21:30:59 -07:00
2024-04-15 08:54:11 -04:00
2024-04-15 08:54:11 -04:00
2024-04-15 08:54:11 -04:00
2024-04-15 08:54:11 -04:00
2024-06-21 19:00:18 -04:00
2024-07-11 12:23:44 +10:00
2024-04-22 11:51:50 -04:00
2024-06-25 17:22:22 +02:00
2024-06-25 17:22:22 +02:00
2024-06-25 17:22:22 +02:00
2024-06-25 17:22:22 +02:00
2024-04-03 16:00:38 +02:00
2024-07-07 17:11:05 +02:00
2024-07-07 17:11:05 +02:00
2024-06-25 17:22:22 +02:00
2024-06-25 17:22:22 +02:00
2024-06-25 17:22:22 +02:00
2024-05-11 15:49:03 -07:00
2024-05-11 15:49:03 -07:00
2024-05-11 15:49:03 -07:00
2024-05-22 12:46:08 -04:00
2024-06-27 08:55:28 +10:00
2024-06-27 08:55:28 +10:00
2024-06-25 17:22:22 +02:00
2024-06-25 17:22:22 +02:00
2024-06-25 17:22:22 +02:00
2024-06-25 17:22:22 +02:00
2024-05-10 12:33:07 -04:00
2024-06-23 22:00:52 +00:00
2024-05-20 19:55:59 -07:00
2024-05-20 11:13:10 -04:00
2024-05-20 11:13:10 -04:00
2024-06-06 19:07:05 +02:00
2024-06-06 19:07:05 +02:00
2024-04-07 01:16:45 +02:00
2024-06-13 20:22:21 +00:00
2024-03-29 22:02:07 +01:00
2024-03-29 22:02:07 +01:00