aboutsummaryrefslogtreecommitdiffstats
path: root/lib/stdlib/src/string.erl
AgeCommit message (Collapse)Author
2018-06-18Update copyright yearHenrik Nord
2018-06-04Fix *case bugs for binariesDan Gudmundsson
Bad optimizing code introduced in 5c51e87bee9d
2018-05-14Optimize string lowercase, uppercase and casefold for ASCII charactersDan Gudmundsson
2018-03-22Revert "Deprecate old string functions"Dan Gudmundsson
It has been decided that it was to early to deprecate the old string functions. This partially reverts commit ccb3f7f9768d3c28783c771df47eec1829e51802.
2018-03-01Merge branch 'maint'Dan Gudmundsson
* maint: ERL-558 Add the missing function clause for string:prefix (#1702)
2018-03-01ERL-558 Add the missing function clause for string:prefix (#1702)Seyed Mirsadeghi
OTP-14942
2017-11-30Merge branch 'maint'Dan Gudmundsson
* maint: Avoid falling measurements testcases on slow machines stdlib: string optimize special case for ASCII stdlib: Minor unicode_util opts
2017-11-29stdlib: string optimize special case for ASCIIDan Gudmundsson
Avoid unicode_util module call for ASCII strings
2017-09-15Deprecate old string functionsDan Gudmundsson
They should not be used.
2017-06-26Fix old length usage in stringDan Gudmundsson
Do not invoke the internal string:lenght/1 function when the list length is wanted. Fixes backwards compatibility for old string functions.
2017-05-22Return error tuple on unicode normalization functionsJosé Valim
Prior to this patch, the normalization functions in the unicode module would raise a function clause error for non-utf8 binaries. This patch changes it so it returns {error, SoFar, Invalid} as characters_to_binary and characters_to_list does in the unicode module. Note string:next_codepoint/1 and string:next_grapheme had to be changed accordingly and also return an error tuple.
2017-05-04Update copyright yearRaimo Niskanen
2017-04-24Handle chardata in string:to_float and string:to_listDan Gudmundsson
2017-04-24New unicode aware string module that works with unicode:chardata()Dan Gudmundsson
Works with unicode:chardata() as input as was decided on OTP board meeting as response to EEP-35 a long time ago. Works on graphemes clusters as base, with a few exceptions, does not handle classic (nor nfd'ified) Hangul nor the extended grapheme clusters such as the prepend class. That would make handling binaries as input/output very slow. List input => list output, binary input => binary output and mixed input => mixed output for all find/split functions. So that results can be post-processed without the need to invoke unicode:characters_to_list|binary for intermediate data. pad functions return lists of unicode:chardata() for performance.
2016-03-15update copyright-yearHenrik Nord
2015-06-18Change license text to APLv2Bruce Yinhe
2015-02-18Optimize string:tokens/2Björn Gustavsson
We can save some time by reversing the original string before starting the tokenization. When there is only one separator, we can save even more time by treating that case specially so that we don't have to call lists:member/2 for each character.
2013-10-14Merge branch 'maint'Fredrik Gustafsson
2013-09-12Remove ^L characters hidden randomly in the code. Not those used in text ↵Pierre Fenoll
files as delimiters. While working on a tool that processes Erlang code and testing it against this repo, I found out about those little sneaky 0xff. I thought it may be of help to other people build such tools to remove non-conforming-to-standard characters.
2013-04-19Remove the "coding: utf-8" comment from all Erlang source filesHans Bolinder
2013-01-25Update copyright yearsBjörn-Egil Dahlberg
2013-01-25Make adjustments for UnicodeHans Bolinder
2013-01-09Prepare OTP files for Unicode as default encodingHans Bolinder
2012-01-27Move types and specs from erl_bif_types.erl to modulesHans Bolinder
2011-05-12Types and specifications have been modified and addedHans Bolinder
2011-03-11Update copyright yearsBjörn-Egil Dahlberg
2010-10-26Fix crash in string:copies/2Michael Santos
Using a float for the number of copies results in an infinite loop. Check that the argument is an integer. Reported-By: Eric Pailleau
2009-11-20The R13B03 release.OTP_R13B03Erlang/OTP