Opened 3 years ago
Closed 3 years ago
#1799 closed enhancement (fixed)
[colorize egg] slow on big files
Reported by: | curium | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | someday |
Component: | extensions | Version: | 5.3.0 |
Keywords: | colorize | Cc: | sjamaan |
Estimated difficulty: |
Description
When trying to colorize big files such as chicken's runtime.c, according to chicken profiler, 96% of time is spent on append at line 296. One enhancement could be to cons tokens and then return the reversed result. Time to colorize runtime.c goes from 10m to 02s.
Another thing which I would like is to have htmlize exported: if someone is using html-colorize, they could need that function to handle a case where the text doesn't need colorization.
Tentative diff attached.
Attachments (1)
Change History (2)
Changed 3 years ago by
Attachment: | colorize.diff added |
---|
comment:1 Changed 3 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
Thanks a bunch, this is a great improvement! I'm a bit embarrassed I overlooked that though ;)
Should be available as 0.5 soonish.
Diff that replaces append with cons, returns reversed result, exports htmlize.