From kde-commits Wed Oct 24 22:09:45 2012 From: Alexander Dymo Date: Wed, 24 Oct 2012 22:09:45 +0000 To: kde-commits Subject: [kdev-ruby] duchain/tests: Test for crash during heredoc parsing. Currently we have two problems: Message-Id: <20121024220945.26DE9A6078 () git ! kde ! org> X-MARC-Message: https://marc.info/?l=kde-commits&m=135111659429528 Git commit 968fa062af989f3a41eff3b391b6bbb17dcd822f by Alexander Dymo. Committed on 25/10/2012 at 00:06. Pushed by dymo into branch 'master'. Test for crash during heredoc parsing. Currently we have two problems: - we treat heredoc as ruby code - we fail during heredoc parsing and crash instead of bailing out M +13 -0 duchain/tests/duchain.cpp M +1 -0 duchain/tests/duchain.h http://commits.kde.org/kdev-ruby/968fa062af989f3a41eff3b391b6bbb17dcd822f diff --git a/duchain/tests/duchain.cpp b/duchain/tests/duchain.cpp index aa582a3..46c4e77 100644 --- a/duchain/tests/duchain.cpp +++ b/duchain/tests/duchain.cpp @@ -396,6 +396,19 @@ void TestDUChain::forStatement() testUnsureTypes(ut, list); } = +void TestDUChain::hereDoc() +{ + // heredoc should be a string and should not be parsed as ruby code + QByteArray code("execute <