Wolfram Function Repository
Instant-use add-on functions for the Wolfram Language
Function Repository Resource:
Find and list all symbols with a particular attribute
| ResourceFunction["SymbolsWithAttribute"][attr] gives a list of the names of symbols that have the given attribute. | |
| ResourceFunction["SymbolsWithAttribute"][attr,patt] gives a list of names matching the string pattern patt. | 
List the names of all available symbols that have the HoldFirst attribute:
| In[1]:= | ![ResourceFunction["SymbolsWithAttribute"][HoldFirst]](https://www.wolframcloud.com/obj/resourcesystem/images/bcb/bcbd3a7d-cd4d-49e9-bb25-6c51fdc3dfe1/1797678cdcc80792.png) | 
| Out[1]= |  | 
List just those symbol names that match the given string pattern:
| In[2]:= | ![ResourceFunction["SymbolsWithAttribute"][HoldFirst, "*To"]](https://www.wolframcloud.com/obj/resourcesystem/images/bcb/bcbd3a7d-cd4d-49e9-bb25-6c51fdc3dfe1/5a2154bf593b3b26.png) | 
| Out[2]= |  | 
List those HoldAll symbols whose name contains "abort" with any capitalization:
| In[3]:= | ![ResourceFunction["SymbolsWithAttribute"][HoldAll, "*abort*", IgnoreCase -> True]](https://www.wolframcloud.com/obj/resourcesystem/images/bcb/bcbd3a7d-cd4d-49e9-bb25-6c51fdc3dfe1/34a09e4a798a74d7.png) | 
| Out[3]= |  | 
List those Protected symbols whose name is similar to "Solve":
| In[4]:= | ![ResourceFunction["SymbolsWithAttribute"][Protected, "Solve", SpellingCorrection -> True]](https://www.wolframcloud.com/obj/resourcesystem/images/bcb/bcbd3a7d-cd4d-49e9-bb25-6c51fdc3dfe1/03ba200658421893.png) | 
| Out[4]= |  | 
Attributes returns all the attributes of a given symbol name:
| In[6]:= | ![RandomChoice[ResourceFunction["SymbolsWithAttribute"][OneIdentity]]](https://www.wolframcloud.com/obj/resourcesystem/images/bcb/bcbd3a7d-cd4d-49e9-bb25-6c51fdc3dfe1/1e1898b63204593c.png) | 
| Out[6]= |  | 
| In[7]:= | ![Attributes["Union"]](https://www.wolframcloud.com/obj/resourcesystem/images/bcb/bcbd3a7d-cd4d-49e9-bb25-6c51fdc3dfe1/7537c5736c3e49d1.png) | 
| Out[7]= |  | 
List all the attributes for each symbol name in the result:
| In[8]:= | ![# -> Attributes[#] &  /@ ResourceFunction["SymbolsWithAttribute"][OneIdentity]](https://www.wolframcloud.com/obj/resourcesystem/images/bcb/bcbd3a7d-cd4d-49e9-bb25-6c51fdc3dfe1/3d1466f9111c0c77.png) | 
| Out[8]= |  | 
Wolfram Language 11.3 (March 2018) or above
This work is licensed under a Creative Commons Attribution 4.0 International License