Commit 9f95ac3
authored
Only add dart format width comment on format (#733)
Closes #724
A use case with a custom `formatCode` callback can reasonably use a
different line width than the default, so only add the width comment
when this package is responsible for performing a format.
Uses with a custom header will no longer slot the width comment in
following the header.
Some outputs will no longer have the comment. This is not breaking since
there has been no published since the comment was introduced.
Files using the shared part builder will need to resolve format width
conflicts using some other mechanism. A shared part file can have
outputs contributed from different code generators that are unrelated,
and may have different behavior around formatting, so it is not possible
to write a single width comment that applies to the combined file.1 parent b7b0c7d commit 9f95ac3
File tree
7 files changed
+34
-35
lines changed- example_usage/lib
- source_gen
- lib
- src
- test
7 files changed
+34
-35
lines changedSome generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
| 16 | + | |
| 17 | + | |
17 | 18 | | |
18 | 19 | | |
19 | 20 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
143 | 143 | | |
144 | 144 | | |
145 | 145 | | |
146 | | - | |
147 | 146 | | |
148 | 147 | | |
149 | 148 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
53 | | - | |
| 53 | + | |
54 | 54 | | |
55 | 55 | | |
56 | 56 | | |
| |||
134 | 134 | | |
135 | 135 | | |
136 | 136 | | |
137 | | - | |
138 | 137 | | |
139 | 138 | | |
140 | 139 | | |
| |||
156 | 155 | | |
157 | 156 | | |
158 | 157 | | |
159 | | - | |
160 | | - | |
161 | 158 | | |
162 | 159 | | |
163 | 160 | | |
| |||
239 | 236 | | |
240 | 237 | | |
241 | 238 | | |
242 | | - | |
| 239 | + | |
243 | 240 | | |
244 | 241 | | |
245 | 242 | | |
| |||
301 | 298 | | |
302 | 299 | | |
303 | 300 | | |
304 | | - | |
| 301 | + | |
305 | 302 | | |
306 | 303 | | |
307 | 304 | | |
| |||
328 | 325 | | |
329 | 326 | | |
330 | 327 | | |
331 | | - | |
| 328 | + | |
| 329 | + | |
332 | 330 | | |
333 | 331 | | |
334 | 332 | | |
| |||
344 | 342 | | |
345 | 343 | | |
346 | 344 | | |
347 | | - | |
| 345 | + | |
348 | 346 | | |
349 | 347 | | |
350 | 348 | | |
| |||
414 | 412 | | |
415 | 413 | | |
416 | 414 | | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
417 | 421 | | |
418 | 422 | | |
419 | 423 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
67 | 67 | | |
68 | 68 | | |
69 | 69 | | |
70 | | - | |
| 70 | + | |
71 | 71 | | |
72 | 72 | | |
73 | 73 | | |
| |||
317 | 317 | | |
318 | 318 | | |
319 | 319 | | |
320 | | - | |
| 320 | + | |
321 | 321 | | |
322 | 322 | | |
323 | 323 | | |
| |||
334 | 334 | | |
335 | 335 | | |
336 | 336 | | |
337 | | - | |
| 337 | + | |
338 | 338 | | |
339 | 339 | | |
340 | 340 | | |
| |||
348 | 348 | | |
349 | 349 | | |
350 | 350 | | |
351 | | - | |
352 | 351 | | |
353 | 352 | | |
354 | 353 | | |
355 | 354 | | |
356 | 355 | | |
357 | 356 | | |
358 | | - | |
| 357 | + | |
359 | 358 | | |
360 | 359 | | |
361 | 360 | | |
| |||
422 | 421 | | |
423 | 422 | | |
424 | 423 | | |
425 | | - | |
| 424 | + | |
426 | 425 | | |
427 | 426 | | |
428 | 427 | | |
| |||
570 | 569 | | |
571 | 570 | | |
572 | 571 | | |
573 | | - | |
574 | 572 | | |
575 | 573 | | |
576 | 574 | | |
| |||
582 | 580 | | |
583 | 581 | | |
584 | 582 | | |
585 | | - | |
586 | 583 | | |
587 | 584 | | |
588 | 585 | | |
| |||
1069 | 1066 | | |
1070 | 1067 | | |
1071 | 1068 | | |
1072 | | - | |
| 1069 | + | |
| 1070 | + | |
1073 | 1071 | | |
1074 | 1072 | | |
1075 | | - | |
1076 | 1073 | | |
1077 | 1074 | | |
1078 | 1075 | | |
| |||
1083 | 1080 | | |
1084 | 1081 | | |
1085 | 1082 | | |
1086 | | - | |
| 1083 | + | |
| 1084 | + | |
1087 | 1085 | | |
1088 | 1086 | | |
1089 | | - | |
1090 | 1087 | | |
1091 | 1088 | | |
1092 | 1089 | | |
| |||
1096 | 1093 | | |
1097 | 1094 | | |
1098 | 1095 | | |
1099 | | - | |
| 1096 | + | |
| 1097 | + | |
1100 | 1098 | | |
1101 | | - | |
1102 | 1099 | | |
1103 | 1100 | | |
1104 | 1101 | | |
| |||
1108 | 1105 | | |
1109 | 1106 | | |
1110 | 1107 | | |
1111 | | - | |
| 1108 | + | |
| 1109 | + | |
1112 | 1110 | | |
1113 | 1111 | | |
1114 | | - | |
1115 | 1112 | | |
1116 | 1113 | | |
1117 | 1114 | | |
| |||
1123 | 1120 | | |
1124 | 1121 | | |
1125 | 1122 | | |
1126 | | - | |
| 1123 | + | |
| 1124 | + | |
1127 | 1125 | | |
1128 | 1126 | | |
1129 | | - | |
1130 | 1127 | | |
1131 | 1128 | | |
1132 | 1129 | | |
| |||
1140 | 1137 | | |
1141 | 1138 | | |
1142 | 1139 | | |
1143 | | - | |
1144 | 1140 | | |
1145 | 1141 | | |
1146 | 1142 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
43 | 43 | | |
44 | 44 | | |
45 | 45 | | |
46 | | - | |
| 46 | + | |
| 47 | + | |
47 | 48 | | |
48 | | - | |
49 | 49 | | |
50 | 50 | | |
51 | 51 | | |
| |||
129 | 129 | | |
130 | 130 | | |
131 | 131 | | |
132 | | - | |
133 | 132 | | |
| 133 | + | |
134 | 134 | | |
135 | 135 | | |
136 | 136 | | |
| |||
166 | 166 | | |
167 | 167 | | |
168 | 168 | | |
169 | | - | |
170 | 169 | | |
| 170 | + | |
171 | 171 | | |
172 | 172 | | |
173 | 173 | | |
| |||
0 commit comments