Skip to content

Xcode 6.1 quickly shutdown when activating breakpoint anywhere #466

@toolbits

Description

@toolbits

I use cpp-netlib 0.11.1RC2 on Xcode 6.1 + Yosemite + boost 1.56.0.
When I use boost::network::uri::uri class and make it's instance, I cannot use Xcode's debugger with breakpoints.
If there is no breakpoints and breakpoints are deactivated, that code run smoothly.
If a breakpoint is installed anywhere, Xcode's debugger quickly hung-up.

I found where is the problem.
Below code is in boost/network/uri/uri.ipp file:

if 0

                    // original code
                    ipv6address %= qi::raw
                    [qi::repeat(6)[h16 >> ':'] >> ls32 |
                     "::" >> qi::repeat(5)[h16 >> ':'] >> ls32 |
                     -qi::raw[h16] >> "::" >> qi::repeat(4)[h16 >> ':'] >> ls32 |
                     -qi::raw[h16] >> "::" >> qi::repeat(3)[h16 >> ':'] >> ls32 |
                     -qi::raw[h16] >> "::" >> qi::repeat(2)[h16 >> ':'] >> ls32 |
                     -qi::raw[h16] >> "::" >> h16 >> ':' >> ls32 |
                     -qi::raw[h16] >> "::" >> ls32 | -qi::raw[h16] >> "::" >> h16 |
                     -qi::raw[h16] >> "::" |
                     -qi::raw[qi::repeat(1)[(h16 >> ':')] >> h16] >> "::" >>
                     qi::repeat(3)[h16 >> ':'] >> ls32 |
                     -qi::raw[qi::repeat(1)[(h16 >> ':')] >> h16] >> "::" >>
                     qi::repeat(2)[h16 >> ':'] >> ls32 |
                     -qi::raw[qi::repeat(1)[(h16 >> ':')] >> h16] >> "::" >> h16 >>
                     ':' >> ls32 |
                     -qi::raw[qi::repeat(1)[(h16 >> ':')] >> h16] >> "::" >> ls32 |
                     -qi::raw[qi::repeat(1)[(h16 >> ':')] >> h16] >> "::" >> h16 |
                     -qi::raw[qi::repeat(1)[(h16 >> ':')] >> h16] >> "::" |
                     -qi::raw[qi::repeat(2)[(h16 >> ':')] >> h16] >> "::" >>
                     qi::repeat(2)[h16 >> ':'] >> ls32 |
                     -qi::raw[qi::repeat(2)[(h16 >> ':')] >> h16] >> "::" >> h16 >>
                     ':' >> ls32 |
                     -qi::raw[qi::repeat(2)[(h16 >> ':')] >> h16] >> "::" >> ls32 |
                     -qi::raw[qi::repeat(2)[(h16 >> ':')] >> h16] >> "::" >> h16 |
                     -qi::raw[qi::repeat(2)[(h16 >> ':')] >> h16] >> "::" |
                     -qi::raw[qi::repeat(3)[(h16 >> ':')] >> h16] >> "::" >> h16 >>
                     ':' >> ls32 |
                     -qi::raw[qi::repeat(3)[(h16 >> ':')] >> h16] >> "::" >> ls32 |
                     -qi::raw[qi::repeat(3)[(h16 >> ':')] >> h16] >> "::" >> h16 |
                     -qi::raw[qi::repeat(3)[(h16 >> ':')] >> h16] >> "::" |
                     -qi::raw[qi::repeat(4)[(h16 >> ':')] >> h16] >> "::" >> ls32 |
                     -qi::raw[qi::repeat(4)[(h16 >> ':')] >> h16] >> "::" >> h16 |
                     -qi::raw[qi::repeat(4)[(h16 >> ':')] >> h16] >> "::" |
                     -qi::raw[qi::repeat(5)[(h16 >> ':')] >> h16] >> "::" >> h16 |
                     -qi::raw[qi::repeat(5)[(h16 >> ':')] >> h16] >> "::" |
                     -qi::raw[qi::repeat(6)[(h16 >> ':')] >> h16] >> "::"];

else

                    // fixed for Xcode 6.1 + boost 1.56.0
                    qi::rule<const_iterator, string_type()> a;
                    qi::rule<const_iterator, string_type()> b;
                    qi::rule<const_iterator, string_type()> c;
                    qi::rule<const_iterator, string_type()> d;
                    a %= qi::repeat(6)[h16 >> ':'] >> ls32 |
                    "::" >> qi::repeat(5)[h16 >> ':'] >> ls32 |
                    -qi::raw[h16] >> "::" >> qi::repeat(4)[h16 >> ':'] >> ls32 |
                    -qi::raw[h16] >> "::" >> qi::repeat(3)[h16 >> ':'] >> ls32 |
                    -qi::raw[h16] >> "::" >> qi::repeat(2)[h16 >> ':'] >> ls32 |
                    -qi::raw[h16] >> "::" >> h16 >> ':' >> ls32 |
                    -qi::raw[h16] >> "::" >> ls32 | -qi::raw[h16] >> "::" >> h16 |
                    -qi::raw[h16] >> "::" |
                    -qi::raw[qi::repeat(1)[(h16 >> ':')] >> h16] >> "::" >> qi::repeat(3)[h16 >> ':'] >> ls32 |
                    -qi::raw[qi::repeat(1)[(h16 >> ':')] >> h16] >> "::" >> qi::repeat(2)[h16 >> ':'] >> ls32 |
                    -qi::raw[qi::repeat(1)[(h16 >> ':')] >> h16] >> "::" >> h16 >> ':' >> ls32;
                    b %= -qi::raw[qi::repeat(1)[(h16 >> ':')] >> h16] >> "::" >> ls32 |
                    -qi::raw[qi::repeat(1)[(h16 >> ':')] >> h16] >> "::" >> h16 |
                    -qi::raw[qi::repeat(1)[(h16 >> ':')] >> h16] >> "::" |
                    -qi::raw[qi::repeat(2)[(h16 >> ':')] >> h16] >> "::" >> qi::repeat(2)[h16 >> ':'] >> ls32 |
                    -qi::raw[qi::repeat(2)[(h16 >> ':')] >> h16] >> "::" >> h16 >> ':' >> ls32;
                    c %= -qi::raw[qi::repeat(2)[(h16 >> ':')] >> h16] >> "::" >> ls32 |
                    -qi::raw[qi::repeat(2)[(h16 >> ':')] >> h16] >> "::" >> h16 |
                    -qi::raw[qi::repeat(2)[(h16 >> ':')] >> h16] >> "::" |
                    -qi::raw[qi::repeat(3)[(h16 >> ':')] >> h16] >> "::" >> h16 >> ':' >> ls32;
                    d %= -qi::raw[qi::repeat(3)[(h16 >> ':')] >> h16] >> "::" >> ls32 |
                    -qi::raw[qi::repeat(3)[(h16 >> ':')] >> h16] >> "::" >> h16 |
                    -qi::raw[qi::repeat(3)[(h16 >> ':')] >> h16] >> "::" |
                    -qi::raw[qi::repeat(4)[(h16 >> ':')] >> h16] >> "::" >> ls32 |
                    -qi::raw[qi::repeat(4)[(h16 >> ':')] >> h16] >> "::" >> h16 |
                    -qi::raw[qi::repeat(4)[(h16 >> ':')] >> h16] >> "::" |
                    -qi::raw[qi::repeat(5)[(h16 >> ':')] >> h16] >> "::" >> h16 |
                    -qi::raw[qi::repeat(5)[(h16 >> ':')] >> h16] >> "::" |
                    -qi::raw[qi::repeat(6)[(h16 >> ':')] >> h16] >> "::";
                    ipv6address %= qi::raw[a | b | c | d];

endif

When I use original code, Xcode hung up. If fixed version is used, Xcode runs well.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions