question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Inline comments include line break

See original GitHub issue

Seems like when inline comments are parsed they include the line break - both in the comment.value and the comment.loc.end

image

Issue Analytics

  • State:open
  • Created 5 years ago
  • Reactions:1
  • Comments:9 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
czoselcommented, Jan 6, 2020

I tried following up on this a little, but can’t report anything conclusive. As far as I can tell, we’re ok with the way things are currently handled, so I wouldn’t prioritize this for 3.0.0.

1reaction
ichiriaccommented, Apr 26, 2018

Ok, got it. In fact I try to stick to original PHP behavior, and sometimes they make strange decisions.

BTW, don’t forget to strip mac & windows returns, just add another check after the first if over “\r” - so you will handle “\n”, “\r\n”, “\r”

I’ll try to look if I can do something directly into the AST even if it would be inconsistent with tokens.

Read more comments on GitHub >

github_iconTop Results From Across the Web

python 3.x - Inline comment with line break - Stack Overflow
My issue is there is no guide on if you want to break lines and also include an inline comment. I have a...
Read more >
How to Add a Line Break in a VBA Code (Single Line into ...
First, click on the character from where you want to break the line. · Next, type a space( ). · After that, type...
Read more >
Guide to Single Line, Inline and Multi Line Comments in Python
First, we will use single-line comments by stating “single-line comment” and then giving one more line. This is specific to using repl.it, if...
Read more >
Hard Line Breaks | Asciidoctor Docs
To preserve a line break in a paragraph, insert a space followed by a plus sign ( + ) at the end of...
Read more >
How about newlines within comments? - Meta Stack Exchange
what we need (and can actually preview while typing a comment, making it more readable, both for the writer -- and the reader,...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found