- Notifications
You must be signed in to change notification settings - Fork670
fix: CodeLens position#426
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
for (let i: number = 0; i < content.length; ++i) { | ||
if (content[i].indexOf("@lc code=end") >= 0) { | ||
let codeLensLine: number = document.lineCount - 1; | ||
for (let i: number = document.lineCount - 1; i >= 0; i--) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
It seems that the algorithm of the@lc code=end
line is different from the algorithm inleetcode-cli.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Any concern for this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
If there are two lines which contain@lc code=end
, We will get inconsistent behavior.
But it is rare, so we don't have to deal with it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Since we have no context information, so this is the case that we cannot deal with no matter what algorithm we take. So let's just keep it as it is.
Thank you for the feedback anyway.
No description provided.