[attribution lost] >>> It's an implementation problem. You find yourself doing a lot of >>> string accessing and pasting, creating several new objects per >>> input char. [Greg Ewing] >> Not necessarily! Plex manages to do it without any >> of that. >> >> The trick is to leave all the characters in the input >> buffer and just *count* how many characters make up >> the next token. [/F] > you can do that without even looking at the characters? 1-character strings are shared; string[i] doesn't create a new object except for the first time that character is seen. string_item() in particular uses the character found to index into an array of 1-character string objects.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4