Commit f30f399
committed
Parser: don't call hasModifier(s) anymore.
Then move jsdoc modifier tag checks into getModifierFlagsNoCache where
they should be. The jsdoc checks are skipped when the parent is
undefined. There are 3 cases when this can happen:
1. The code is in the parser (or a few places in the binder, notably
declareSymbol of module.exports assignments).
2. The node is a source file.
3. The node is synthetic, which I assume to be from the transforms.
It is fine to call getModifierFlags in cases (2) and (3). It is not fine
for (1), so I removed these calls and replaced them with simple
iteration over the modifiers. Worth noting: Ron's uniform node construction
PR removes these calls anyway; this PR just does it early.1 parent 62a568d commit f30f399
File tree
5 files changed
+29
-28
lines changed- src/compiler
- transformers
5 files changed
+29
-28
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5322 | 5322 | | |
5323 | 5323 | | |
5324 | 5324 | | |
5325 | | - | |
| 5325 | + | |
5326 | 5326 | | |
5327 | 5327 | | |
5328 | 5328 | | |
| |||
6102 | 6102 | | |
6103 | 6103 | | |
6104 | 6104 | | |
6105 | | - | |
| 6105 | + | |
6106 | 6106 | | |
6107 | 6107 | | |
6108 | 6108 | | |
| |||
28360 | 28360 | | |
28361 | 28361 | | |
28362 | 28362 | | |
28363 | | - | |
28364 | | - | |
| 28363 | + | |
| 28364 | + | |
28365 | 28365 | | |
28366 | 28366 | | |
28367 | 28367 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2584 | 2584 | | |
2585 | 2585 | | |
2586 | 2586 | | |
2587 | | - | |
| 2587 | + | |
2588 | 2588 | | |
2589 | 2589 | | |
2590 | 2590 | | |
| |||
3603 | 3603 | | |
3604 | 3604 | | |
3605 | 3605 | | |
3606 | | - | |
| 3606 | + | |
3607 | 3607 | | |
3608 | 3608 | | |
3609 | 3609 | | |
| |||
3809 | 3809 | | |
3810 | 3810 | | |
3811 | 3811 | | |
3812 | | - | |
| 3812 | + | |
3813 | 3813 | | |
3814 | 3814 | | |
3815 | 3815 | | |
| |||
5005 | 5005 | | |
5006 | 5006 | | |
5007 | 5007 | | |
5008 | | - | |
| 5008 | + | |
5009 | 5009 | | |
5010 | 5010 | | |
5011 | 5011 | | |
| |||
5834 | 5834 | | |
5835 | 5835 | | |
5836 | 5836 | | |
5837 | | - | |
| 5837 | + | |
5838 | 5838 | | |
5839 | | - | |
| 5839 | + | |
5840 | 5840 | | |
5841 | 5841 | | |
5842 | 5842 | | |
| |||
5869 | 5869 | | |
5870 | 5870 | | |
5871 | 5871 | | |
5872 | | - | |
| 5872 | + | |
5873 | 5873 | | |
5874 | 5874 | | |
5875 | 5875 | | |
| |||
6511 | 6511 | | |
6512 | 6512 | | |
6513 | 6513 | | |
6514 | | - | |
| 6514 | + | |
6515 | 6515 | | |
6516 | 6516 | | |
6517 | 6517 | | |
| |||
6528 | 6528 | | |
6529 | 6529 | | |
6530 | 6530 | | |
| 6531 | + | |
| 6532 | + | |
| 6533 | + | |
| 6534 | + | |
| 6535 | + | |
6531 | 6536 | | |
6532 | 6537 | | |
6533 | 6538 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1473 | 1473 | | |
1474 | 1474 | | |
1475 | 1475 | | |
1476 | | - | |
| 1476 | + | |
1477 | 1477 | | |
1478 | 1478 | | |
1479 | 1479 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4100 | 4100 | | |
4101 | 4101 | | |
4102 | 4102 | | |
4103 | | - | |
| 4103 | + | |
4104 | 4104 | | |
4105 | 4105 | | |
4106 | 4106 | | |
| |||
4121 | 4121 | | |
4122 | 4122 | | |
4123 | 4123 | | |
4124 | | - | |
4125 | | - | |
4126 | | - | |
4127 | | - | |
4128 | | - | |
4129 | | - | |
4130 | | - | |
4131 | | - | |
4132 | | - | |
4133 | | - | |
4134 | | - | |
4135 | | - | |
| 4124 | + | |
| 4125 | + | |
| 4126 | + | |
4136 | 4127 | | |
4137 | 4128 | | |
4138 | 4129 | | |
4139 | | - | |
| 4130 | + | |
| 4131 | + | |
| 4132 | + | |
| 4133 | + | |
| 4134 | + | |
4140 | 4135 | | |
| 4136 | + | |
4141 | 4137 | | |
4142 | 4138 | | |
4143 | 4139 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
299 | 299 | | |
300 | 300 | | |
301 | 301 | | |
302 | | - | |
| 302 | + | |
303 | 303 | | |
304 | 304 | | |
305 | 305 | | |
| |||
0 commit comments