id,summary,reporter,owner,description,type,status,milestone,component,version,severity,resolution,keywords,cc 4671,std::bad_cast crash seems to be linked to boost_regex,Spinach ,John Maddock,"I've gotten the exact same code compiled on Ubuntu and am now trying to get my program working on a MacOS 10.6.4. I installed boost 1.4.4 as root using ./bootstrap.sh and then ./bjam I also performed the following: ./bjam install variant=debug define=_GLIBCXX_DEBUG --with-regex I compiled the program using Codeblocks (without any errors) but when I run the program I get the following error: {{{ }}} {{{ ./graph_search terminate called after throwing an instance of 'std::bad_cast' what(): std::bad_cast Abort trap }}} When I look into the error using Console, I see the following error {{{ Thread 0 Crashed: Dispatch queue: com.apple.main-thread 0 libSystem.B.dylib 0x00007fff837c33d6 __kill + 10 1 libSystem.B.dylib 0x00007fff83863972 abort + 83 2 libstdc++.6.dylib 0x00007fff826785d2 __tcf_0 + 0 3 libstdc++.6.dylib 0x00007fff82676ae1 __cxxabiv1::__terminate(void (*)()) + 11 4 libstdc++.6.dylib 0x00007fff82676b16 __cxxabiv1::__unexpected(void (*)()) + 0 5 libstdc++.6.dylib 0x00007fff82676bfc __gxx_exception_cleanup(_Unwind_Reason_Code, _Unwind_Exception*) + 0 6 libstdc++.6.dylib 0x00007fff8263293f std::__throw_bad_alloc() + 0 7 libboost_regex.dylib 0x00000001000c34b8 std::collate const& std::use_facet >(std::locale const&) + 85 (locale_facets.tcc:117) 8 libboost_regex.dylib 0x000000010009b794 boost::re_detail::cpp_regex_traits_base::imbue(std::locale const&) + 124 (cpp_regex_traits.hpp:218) 9 libboost_regex.dylib 0x00000001000cde35 boost::re_detail::cpp_regex_traits_base::cpp_regex_traits_base(std::locale const&) + 43 (cpp_regex_traits.hpp:173) 10 libboost_regex.dylib 0x00000001000cde83 boost::shared_ptr const> boost::re_detail::create_cpp_regex_traits(std::locale const&) + 30 (cpp_regex_traits.hpp:852) 11 libboost_regex.dylib 0x00000001000cdeed boost::cpp_regex_traits::cpp_regex_traits() + 35 (cpp_regex_traits.hpp:872) 12 libboost_regex.dylib 0x00000001000cdf33 boost::regex_traits >::regex_traits() + 21 (regex_traits.hpp:75) 13 libboost_regex.dylib 0x00000001000cdf4b boost::regex_traits_wrapper > >::regex_traits_wrapper() + 21 (regex_traits.hpp:169) 14 libboost_regex.dylib 0x00000001000cdf8d boost::re_detail::regex_data > >::regex_data() + 63 (basic_regex.hpp:212) 15 libboost_regex.dylib 0x00000001000ce041 boost::re_detail::basic_regex_implementation > >::basic_regex_implementation() + 21 (basic_regex.hpp:248) 16 libboost_regex.dylib 0x000000010009b815 boost::basic_regex > >::do_assign(char const*, char const*, unsigned int) + 75 (basic_regex.hpp:698) 17 graph_search 0x00000001000055e5 main + 773 18 graph_search 0x0000000100001048 start + 52 Thread 0 crashed with X86 Thread State (64-bit): rax: 0x0000000000000000 rbx: 0x00007fff7066e2d8 rcx: 0x00007fff5fbfdc18 rdx: 0x0000000000000000 rdi: 0x000000000000a367 rsi: 0x0000000000000006 rbp: 0x00007fff5fbfdc30 rsp: 0x00007fff5fbfdc18 r8: 0x0000000000000000 r9: 0x0000000100600460 r10: 0x00007fff837bf412 r11: 0x0000000000000202 r12: 0x00007fff8267b530 r13: 0x0000000100600420 r14: 0x0000000000000000 r15: 0x0000000000000000 rip: 0x00007fff837c33d6 rfl: 0x0000000000000202 cr2: 0x00007fff7067f058 }}} I would be so appreciative of any help anyone could provide. Thank you, Spinach ",Bugs,closed,To Be Determined,regex,Boost 1.44.0,Problem,worksforme,,