Data.String: refactor replace() and replace_once()

change to use substitute() for performance.
Data.String: bugfix infinite loop in scan()

bugfix infinite loop in scan() when matched
string is empty.
And improve performance.
Merge pull request #82 from deris/refactor/replace

Data.String: refactor replace() and replace_once()
Merge pull request #83 from deris/bugfix/scan

Data.String: bugfix infinite loop in scan()