let symbol_of_smtlib_atom s = try (* Map hashconsed string to symbol *) HString.HStringHashtbl.find hstring_symbol_table s (* String is not one of our symbols *) with Not_found -> (* Check if string is a reserved word *) if List.memq s smtlib_reserved_word_list then (* Cannot parse S-expression *) raise (Invalid_argument (Format.sprintf "Unsupported reserved word '%s' in S-expression" (HString.string_of_hstring s))) else (* String is not a symbol *) raise Not_found