10000 Speed up HTML encoder for 1.2 by korny · Pull Request #153 · rubychan/coderay · GitHub
[go: up one dir, main page]

Skip to content

Speed up HTML encoder for 1.2 #153

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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 19 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
don't escape /
  • Loading branch information
korny committed Jun 12, 2016
commit 351822b9e9ed27d0b58c39ad93dba9bf64615920
2 changes: 1 addition & 1 deletion lib/coderay/encoders/html.rb
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ def finish options
def text_token text, kind
style = @span_for_kinds[@last_opened ? [kind, *@opened] : kind]

text = EscapeUtils.escape_html text
text = EscapeUtils.escape_html text, false
text = break_lines(text, style) if @break_lines && (style || @opened.size > 0) && text.index("\n")

if style
Expand Down
0