generate_packets.py: unify parsing of block comments and EOL comments
Part of #43927. Follow-up to #44571. The current two-step process can cause unintuitive behavior in edge cases where the two comment types are mixed. Process both of them at once with a single regex.
Depends on #44571. Does not interfere with #44563
Part of #43927. Follow-up to #44571. The current two-step process can cause unintuitive behavior in edge cases where the two comment types are mixed. Process both of them at once with a single regex.