Created
November 24, 2012 13:24
-
-
Save nox/4139688 to your computer and use it in GitHub Desktop.
erlang:list_to_atom/2
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
erlang:list_to_atom(string(), [global | safe]). | |
string | options | result | |
---------------+--------------------------+--------------------------- | |
"not_existing" | global | not_existing (global) | |
"existing" | global | existing (global) | |
"not_existing" | safe | not_existing (local) | |
"existing" | safe | existing (global) | |
"not_existing" | global, safe | FAILURE | |
"existing" | global, safe | existing (global) | |
erlang:list_to_atom(List) -> erlang:list_to_atom(List, [safe]). | |
erlang:list_to_existing_atom(List) -> erlang:list_to_atom(List, [global, safe]). |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment