See also
and also
Tests are good
Unit test code for atom_chars/2, also working as documentation:
A stringy replacement
After some consideration, the use of atom_chars/2 and string_chars/2 has been prohibited in this house and stringy_chars/2 shall be used instead uniformly! No need to choose on the level of the predicate name anymore, which makes your mind vaccillate on the cusp of a low-level decision. Just use an additional argument:
As in:
stringy_chars(Text, [f,o,o], string). % ... gives "foo" stringy_chars(Text, [f,o,o], atom). % ... gives 'foo' stringy_chars("foo", Chars, Want). % ... gives [Chars,Want] == [[f,o,o],string] stringy_chars(foo, Chars, Want). % ... gives [Chars,Want] == [[f,o,o],atom]