Commit Graph

707 Commits

Author SHA1 Message Date
Frederich Munch
4b6ae92419 Split getcwd tests into two files as Windows cannot pass one of the tests. 2016-12-06 20:44:05 +01:00
Frederich Munch
0a995d8b3d Revert "Simplify; make Windows compatible (cannot delete cwd)."
This reverts commit 2459221755.
2016-12-06 20:44:05 +01:00
Bertrand Bellenot
2459221755 Simplify; make Windows compatible (cannot delete cwd). 2016-12-06 16:14:25 +01:00
Axel Naumann
372c3243bf MacOS messes up unicode file names with old git. 2016-12-02 11:29:08 +01:00
Axel Naumann
cab3c10849 Revert "Fix UTF8 encoding for _42_Semmel_Knödel."
Makes the tests fail on Linux.
This reverts commit e666cfc7b0d141aff54e380c2f7f63e85ae23646.
2016-12-01 17:44:07 +01:00
Frederich Munch
c534930b64 Fix UTF8 encoding for _42_Semmel_Knödel. 2016-12-01 17:29:08 +01:00
Bertrand Bellenot
fdf057e19a Cannot use tick as quote on Windows.' 2016-11-30 11:14:29 +01:00
Bertrand Bellenot
f8f73fd444 On Windows we need -nostdinc as C and C++ header locations are identical. 2016-11-30 10:14:14 +01:00
Bertrand Bellenot
79d830c122 Test cannot succeed on Windows due to DLL / dyn linker behavior. 2016-11-30 10:14:14 +01:00
Bertrand Bellenot
1f6b27c24c Make non-windows selectable for tests. 2016-11-30 10:14:13 +01:00
Axel Naumann
5e14792560 Add test for ROOT-8467. 2016-11-28 17:44:15 +01:00
Roman Zulak
9157aad03e Fix printing of std::map broken in 1e004e9.
Signed-off-by: Vassil Vassilev <vvasilev@cern.ch>
2016-11-23 12:59:23 +01:00
Roman Zulak
1e004e9d3a Fix printing of collections. Make it impossible for a collection with 1 element to match the string of an empty collection. Avoid checking if comma needs to be added in loop. Make an empty tuple print same as empty collection: '{}'.
Signed-off-by: Vassil Vassilev <vvasilev@cern.ch>
2016-11-21 12:44:34 +01:00
Roman Zulak
c91e902f58 Windows: Fix print QualType's that can be severely hidden in layers of typedefs.
Signed-off-by: Vassil Vassilev <vvasilev@cern.ch>
2016-11-21 12:44:34 +01:00
Philippe Canal
39ea2ba5c2 Extent autoforwarding test with more include nesting case 2016-11-18 01:29:09 +01:00
Philippe Canal
d066ad6061 Add test of the case where the definition are indirectly included 2016-11-14 03:14:37 +01:00
Philippe Canal
1bd0822562 Test for ROOT-8443
Test clean-up of forward decl with or without template default parameter and user forward decl
also with or without template default parameter and located before or after the inclusion
of the annotated/dictionary forward decls.
2016-11-14 03:14:37 +01:00
Philippe Canal
6920d6d460 Add cling version of test for ROOT-7037 2016-11-14 03:14:37 +01:00
Roman Zulak
74cb06a22f Fixes issues where symbols can be improperly aligned for llvm::PointerIntPair Use std::pair instead of llvm::PointerIntPair.
Signed-off-by: Vassil Vassilev <vvasilev@cern.ch>
2016-10-19 13:54:07 +02:00
Roman Zulak
1dadbe2495 Refactor CheckABICompatibility into a more legible version. Standardize error message. Return whether the ABI matched or not.
Signed-off-by: Vassil Vassilev <vvasilev@cern.ch>
2016-10-18 17:53:21 +02:00
Vassil Vassilev
fbd110fc67 When deciding not to wrap add the last token ';' we advanced to.
This fixes Github issue 113, breaking Jupiter notebooks.
2016-10-16 11:39:16 +02:00
Axel Naumann
1ce8341b6d Add newline at end of file. 2016-09-27 10:29:55 +02:00
Frederich Munch
2bf05c5188 Fix extern "C" declarations not being called from .x command.
This handles top-level declarations only (i.e. not nested in namespaces).
2016-09-16 21:39:49 +02:00
Frederich Munch
c6b24d764c Fix TransactionPool placement new and delete.
TransactionPool was using placement new and delete improperly which could lead to Transaction::~Transaction running twice.
Make Transaction constructor private to make sure TransactionPool has allocated all Transactions it contains.
Remove "*Very useful for debugging purposes" leak on every allocation.
2016-09-12 17:29:20 +02:00
Axel Naumann
b56389eebe Add test for ROOT-7610. 2016-09-06 10:14:21 +02:00
Axel Naumann
22925c8b0a Add test against ROOT-5248. 2016-09-05 12:59:28 +02:00
Axel Naumann
580f6bee47 Add test against ROOT-7857. 2016-09-05 12:59:28 +02:00
Axel Naumann
31486e784e Add test against ROOT-8300, fixed by wrapper improvements by Roman. 2016-09-05 12:59:28 +02:00
Frederich Munch
5bb4fc3e8d More complete function/class wrap detection.
Handle C++ class scoping for unwrapped function/method definitions.
Handle source that begins with a function/method that should't be wrapped and
is followed by statements that should be.
2016-09-05 12:44:13 +02:00
Frederich Munch
be7769aa5d Remove .rawInput from a variety of tests to test unwrapped function input. 2016-09-05 12:44:13 +02:00
Frederich Munch
c86cd5bc6c Allow struct and class return types from function definitions. 2016-09-05 12:44:12 +02:00
Frederich Munch
1bb3b96d2f Don't wrap function, method, constructor, or destructor definitions. 2016-09-05 12:44:12 +02:00
Frederich Munch
4a45f0bc51 Fix x86 dependency in test/UnknownType.C 2016-09-05 08:29:46 +02:00
Frederich Munch
cb0e5cf94a Fix crash when first thing printed in a session is a function 2016-09-02 12:59:54 +02:00
Frederich Munch
415483c07e Gracefully handle unknown type expressions.
Prior behavior crashed, now an error printed.
Add test/Prompt/ValuePrinter//UnkownType.C.
2016-09-02 12:59:54 +02:00
Axel Naumann
d9760070f6 Fix and simplify.
The original implementation would have needed multiple calls to ChildMP.process() for the value printing to work.
2016-08-29 12:14:42 +02:00
Axel Naumann
a302f3c002 Do not violate contract of frozen parent. 2016-08-29 09:29:15 +02:00
Axel Naumann
f6bfab6b2a XFAIL until I understand the failure. 2016-08-26 17:14:22 +02:00
Roman Zulak
8688067f1c Changing output name call.C test.
Hopefully this removes intermittent test failures because of a race condition where
two tests were attempting to write to the same file.

Signed-off-by: Vassil Vassilev <vvasilev@cern.ch>
2016-08-21 10:29:24 +02:00
Frederich Munch
bbfd61d897 Share -v flag with clang, and use it during startup to log info about header search paths.
Also fix trying to report why compiler invocation failed when it was never attempted.
Add message about build being probably being configured incorrectly.

Signed-off-by: Vassil Vassilev <vvasilev@cern.ch>
2016-08-18 15:44:18 +02:00
Frederich Munch
5ee1cfb7c3 Refactor all argument parsing into InvocationOptions.cpp.
Signed-off-by: Vassil Vassilev <vvasilev@cern.ch>
2016-08-18 15:44:18 +02:00
Frederich Munch
2142853de6 Don't call clang::ApplyHeaderSearchOptions from Interpreter::AddIncludePaths.
Instead call it at the end of cling::createCI (that should probably change too).

clang::ApplyHeaderSearchOptions is a very heavy-weight function that does a lot
of work to determine and add system headers. More importantly it can also wind
up invalidating clangs internal cache making inclusion of files later impossible.

By using the lighter HeaderSearchOptions::AddSearchPath we not only avoid redoing
a lot of work that has been done, but can adjust the method in clang to avoid
cache invalidation so that calling Interpreter::AddIncludePath will actually
make the files in that path accessible to clang.

Signed-off-by: Vassil Vassilev <vvasilev@cern.ch>
2016-08-18 15:44:18 +02:00
Frederich Munch
4cdbc0461e Honor clangs -nostdinc++ and -nobuiltininc flags.
Rename AddHostCXXIncludes  to AddHostIncludes and delineate between -nostdinc++
and -nobuiltininc. When cling is invoked with -nobuiltininc, do not #include any runtime
files on startup.  Make ABI incompatability error consistent across platforms and add a test to verify behavior when this occurs.

More importantly this allow for easier debugging of Decl unloading as the amount of
declarations on startup is greatly reduced.

Signed-off-by: Vassil Vassilev <vvasilev@cern.ch>
2016-08-18 15:44:17 +02:00
Frederich Munch
109812d223 Fix crash from possible null return from getcwd. 2016-08-12 14:29:07 +02:00
Frederich Munch
bcb75e1476 Don't create a virtual file with a valid file name.
This fix allows running a file in the current working directory.
2016-08-12 14:29:07 +02:00
Frederich Munch
a7f5c1719e Set CLING_NOHISTORY when running tests. 2016-08-12 14:14:06 +02:00
Frederich Munch
e3265d1d8c Add %built_cling substitution for lit so tests can be run from either the build or installations directories. 2016-08-12 14:14:06 +02:00
Frederich Munch
a875004a73 Fix check-cling target, broken in commit b461173.
Signed-off-by: Bertrand Bellenot <bertrand.bellenot@cern.ch>
2016-08-11 10:59:21 +02:00
Bertrand Bellenot
3c3c027663 Keep the Cling copyright header 2016-08-08 11:29:09 +02:00
Bertrand Bellenot
b46117358a Use the same CMake cling test architecture than the clang tests 2016-08-08 11:14:16 +02:00
Axel Naumann
6b06b7344b The "." is needed for lit to parse the regex; require 5*hex. 2016-07-30 21:14:15 +02:00
Axel Naumann
be22fa6165 Fix spelling of CPP check. 2016-07-30 13:14:13 +02:00
Axel Naumann
214dcfc40f Do not require extra char after 6 hex-digit ptrs. 2016-07-30 13:14:13 +02:00
Axel Naumann
494733cef8 JIT exception support missing for powerpc64. 2016-07-30 00:43:09 +02:00
Axel Naumann
92716fcdc6 Do not expose x86 asm to Power8. 2016-07-30 00:14:22 +02:00
Frederich Munch
f59228426b Fix writing files to source directory, write to build directory instead. 2016-07-22 12:44:12 +02:00
Axel Naumann
d9eea3590b Add test for ROOT-8077. 2016-07-21 19:29:07 +02:00
Axel Naumann
d4e01536f8 Make it fail! 2016-07-21 17:44:08 +02:00
Axel Naumann
ffec1df67b Only refuse decl extraction if ill-formed; add test; move KnownFail out. 2016-07-21 15:59:24 +02:00
Axel Naumann
a26c3cf033 Try to fix test failure in Travis. 2016-07-14 14:14:15 +02:00
Axel Naumann
7e9a74f3e4 Remove remnants of llvm configure/make build system. 2016-07-13 17:16:13 +02:00
Axel Naumann
0ad3a09203 Cope with new diag notes 2016-07-12 10:44:20 +02:00
Vassil Vassilev
af2cded628 Add consistent to llvm and clang target name to run the testsuite. 2016-07-08 11:29:29 +02:00
Philippe Canal
a573e3340b Add test of null pointer checking in function template 2016-06-30 03:14:17 +02:00
Axel Naumann
f9a8254617 Work around ROOT-8240. 2016-06-27 09:59:08 +02:00
Axel Naumann
1514d41841 Missing decl of printf. 2016-06-27 08:44:24 +02:00
Axel Naumann
fcb6aafd9e Fix file name. 2016-06-27 00:14:05 +02:00
Axel Naumann
7e1ee6da3a Add test for ROOT-7858. 2016-06-26 20:29:05 +02:00
Axel Naumann
e65d942ffa Add test for ROOT-8036. 2016-06-26 20:14:04 +02:00
Axel Naumann
7b0276fcae Remove platform-specific code (fails on Darwin), just use cannotCallWithNull. 2016-06-17 15:14:08 +02:00
Axel Naumann
f2326da23d Remove XFAIL now that the JIT can handle exceptions (at least on darwin). 2016-06-15 15:10:51 +02:00
Axel Naumann
1091b41295 Port test/CodeUnloading to CMake. Less failures than before! 2016-06-15 14:14:34 +02:00
Axel Naumann
47a6a5f288 Add %llvmsrcdir replacement. Remove leading space (?!). 2016-06-15 14:14:34 +02:00
Axel Naumann
f32d1a9ec7 Simplify test - import of string literals is not supported. 2016-06-15 14:14:33 +02:00
Axel Naumann
752dcfbb54 Adapt test to new style of scope dumps 2016-06-15 14:14:33 +02:00
Axel Naumann
6d3070de94 No exceptions in the (old) JIT of cling on powerpc64 either. 2016-03-31 10:29:07 +02:00
Axel Naumann
6d5b15306b XFAIL should be "arm64,aarch64", not "arm". 2016-03-31 09:44:06 +02:00
Axel Naumann
ac05121825 The (old) llvm JIT in cling does not support exceptions on either ARM64 not AARCH64. 2016-03-31 09:44:06 +02:00
Axel Naumann
3c31044732 Do not rely on debug output. Fix code. 2016-03-30 12:44:14 +02:00
Axel Naumann
0d827a761a Add test for ROOT-7837. 2016-03-04 21:29:05 +01:00
Axel Naumann
21588e64c2 This test is a no-op in CMake - we need to fix that. 2016-02-05 16:14:04 +01:00
Axel Naumann
2b58f4ad21 Rename to match more generic content. 2016-02-05 11:59:04 +01:00
CristinaCristescu
2906250d08 Add lambda test for null deref. 2016-02-05 11:59:04 +01:00
Axel Naumann
a8dcd932fe Fix expected enum value printing (underlying type). 2016-02-04 18:14:08 +01:00
Danilo Piparo
c07e92e42d Add test for empty tuple. 2016-02-04 15:29:16 +01:00
Axel Naumann
8621eb091a Simplify regex; #includes; std::. 2016-02-02 20:59:04 +01:00
Danilo Piparo
90fe0e262e Add to cling value printing capabilities for std::tuple and std::pair. 2016-02-02 12:59:25 +01:00
Axel Naumann
5587ae57e6 Test for ROOT-7918. 2016-01-31 21:29:07 +01:00
Axel Naumann
ba2d25f20a No diags! Really do iter deref. User fwd decl. 2016-01-28 15:12:50 +01:00
CristinaCristescu
0329828fd8 Add tests for cling NullDeref.
If stmt testing and checking that the execution is stopped after
a null deref warning.
2016-01-28 15:12:50 +01:00
Axel Naumann
5fb064400f Add test for ROOT-7426. 2016-01-28 15:12:50 +01:00
Axel Naumann
fd8be83d46 Revert unintentional add. 2016-01-14 20:59:08 +01:00
Elisavet Sakellari
e6487af04a Forgot to remove commented code 2016-01-14 20:44:14 +01:00
Elisavet Sakellari
ef6320070f Additional minor changes 2016-01-14 20:44:14 +01:00
Elisavet Sakellari
01a4526fc6 Edited test for Multiple Interps, and added some fixes 2016-01-14 20:44:14 +01:00
Elisavet Sakellari
4ac0a10a3e Added test for MultipleInterpreters, and some changes. 2016-01-14 20:44:14 +01:00
Axel Naumann
abf65cb689 Typo. 2016-01-13 10:14:06 +01:00
Axel Naumann
62ea6ec80a Do not rely on init_list intricacies. 2016-01-13 09:59:04 +01:00
Axel Naumann
1044052eed Range-based for loop requires type for loop variable. 2016-01-13 09:59:04 +01:00
Axel Naumann
d60d4e76be Two missing CMake vars for lit.cfg. 2016-01-12 12:27:43 +01:00
Axel Naumann
5c22ebb509 Do not print invalid memory. 2016-01-04 17:44:24 +01:00
Axel Naumann
a4a3ebbb41 Fix expectation to match (correct) reality. 2016-01-02 20:48:01 +01:00
CristinaCristescu
b8d475fd0c Add invalid deref tests. 2015-12-18 12:44:09 +01:00
Axel Naumann
473e16a131 Remove non-existing "cling-headers" dependency. 2015-12-16 20:29:22 +01:00
CristinaCristescu
95e3dcf8ef Check for invalid pointer address access. 2015-12-15 20:24:16 +01:00
CristinaCristescu
982a3ae38b Enable the NullDeref Cling test for MethodCalls. 2015-12-15 20:24:16 +01:00
Philippe Canal
4ba468335e Adapt output to tweaked behavior 2015-09-29 19:18:04 +02:00
Axel Naumann
dec5717d4c Fix printing of false! (And add a test.) 2015-08-21 12:23:04 +02:00
Boris Perovic
f268b40976 Dtors.c cling test changed in order to avoid infinite loop when unloading "RuntimePrintValue.h". Should be looked into in the future. 2015-08-20 17:06:02 +02:00
Boris Perovic
800c644352 Removed "VALID" after address output, fixes roottest. Various fixes based on comments after second round. 2015-08-18 18:08:20 +02:00
Boris Perovic
2d317b983d Fixes based on cling test suite ("make test"). 2015-08-18 18:08:20 +02:00
Boris Perovic
c44940b223 New printValue() integration (printing unified through overloading of printValue() function and template resolution). Modified tests to conform to the new prints. 2015-08-17 18:45:03 +02:00
Axel Naumann
4b08f20793 Fix runtime / PCH incompatibility. 2015-06-26 14:44:19 +02:00
Elisavet Sakellari
bfa9947c5a Implement search path cling pragma / ROOT macros (ROOT-7269). 2015-06-04 16:40:08 +02:00
Axel Naumann
5cfdd233c2 Test for ROOT-7295. 2015-06-04 11:30:15 +02:00
Liza
99de1fe5c0 ROOT-7031 bug fix for illegal macros. 2015-05-21 20:24:10 +02:00
Axel Naumann
1508b73c7c Add test for ROOT-7310. 2015-05-13 12:12:00 +02:00
Axel Naumann
31a9d9d0b2 Make test more telling. 2015-04-04 20:51:20 +02:00
Axel Naumann
2b0371b779 Adapt expectation to reality. 2015-04-03 21:58:12 +02:00
Axel Naumann
104540e8af Test for ROOT-7163. 2015-04-01 12:09:20 +02:00
Axel Naumann
97b8a20df8 Also copy include/llvm-c headers; cling-test needs them. 2015-04-01 12:09:15 +02:00
Liza Sakellari
529b0aed53 Fixed parsing of '\'' at the prompt (ROOT-7159). 2015-03-31 16:47:10 +02:00
Liza Sakellari
4de2d7d77c Fixed Parser error when calling a macro with arguments. 2015-03-31 16:47:09 +02:00
Liza Sakellari
19ce2d03b6 Fixed bug "Parser error when calling a macro with arguments". 2015-03-31 16:47:09 +02:00
Pere Mato
d38891b490 Use the make variable TESTDIRS to select the test directories for cling-test 2015-03-30 22:53:10 +02:00
Pere Mato
20e2f24106 Fix for ROOT-7184 - CMake config issue when enabling cling tests 2015-03-13 18:31:50 +01:00
Axel Naumann
18d0c4e740 Test for ROOT-7113: pragma once on prompt. 2015-02-27 11:05:19 +01:00
Axel Naumann
ea39f4e821 Fatal line mess - extract decl out of #if. 2015-02-25 21:28:10 +01:00
Axel Naumann
9bef38e844 Test inline asm at least on linux. 2015-02-25 20:37:12 +01:00
Axel Naumann
18437175a8 Add test for ROOT-6531. 2015-02-22 00:09:36 +01:00
Axel Naumann
e582b93a16 No #include <new> in C mode; add basic C mode test (ROOT-7090). 2015-02-21 22:43:36 +01:00
Axel Naumann
69234ce153 Fix nullptr value printing (ROOT-7092). 2015-02-21 22:27:26 +01:00
Axel Naumann
c1cf9236c0 Also test error recovery from non-existing file. 2015-02-18 14:51:21 +01:00
Axel Naumann
1ffc20a6b2 Add a cling pragma handler. For now implement #pragma cling load(file)
Extremely handy for sources that require certain libraries to be loaded;
it's similar to MSVC's #pragma comment(lib"libToLink").
2015-02-18 14:51:21 +01:00
Axel Naumann
d9a804df73 OrcJIT emits only call dependencies. 2015-02-11 10:57:47 +01:00
Axel Naumann
ae0290a4fb Follow change in warning; add new warning. 2015-02-11 10:57:46 +01:00
Axel Naumann
020f962990 Follow interface change (unique_ptr). 2015-02-11 10:57:44 +01:00
Axel Naumann
2deb711ce1 Make test more readable. 2015-02-11 10:57:41 +01:00
Axel Naumann
9c383fcef3 clang is built without rtti; no chance to find its typeinfo. 2015-02-11 10:57:39 +01:00
Axel Naumann
e4da5f2858 Error now comes during reloc (static init). 2015-02-11 10:57:39 +01:00
Axel Naumann
1e8f686cf2 Update location of "missing symbol" error:
The resolution now happens during relocation, not just at the call.
A failure thereof causes the transaction to be reverted which makes
bar() undeclared.
2015-02-11 10:57:38 +01:00
Axel Naumann
1497128ee7 Add test for ROOT-6650. 2014-12-16 11:06:04 +01:00
Axel Naumann
71fc16baf4 Give cling the LangOpts clang has. 2014-10-21 20:09:02 +02:00
Axel Naumann
9b30bafdbc Adapt to new Transform::Config::m_toSkip. 2014-10-16 11:26:07 +02:00
Vassil Vassilev
0764694c14 Do not try to fixup return statements in lambdas. 2014-10-08 17:42:04 +02:00
Vassil Vassilev
32d06e92f0 Add the expected string also. 2014-10-06 15:44:09 +02:00
Vassil Vassilev
5d672fe795 Improve " and ' balancing. Fixes ROOT-6791. 2014-10-06 15:44:09 +02:00
Axel Naumann
fd9f5defab Mention current failure rate of Sema unloading tests. 2014-10-02 16:20:03 +02:00
Axel Naumann
0a73f180e6 Determing cling location from script location. 2014-10-02 16:20:03 +02:00
Philippe Canal
2febce4e88 Revert remove trailing space for interpreter/cling/test/Prompt/MetaProcessor/Regression.C 2014-10-02 09:45:05 +02:00
Vassil Vassilev
a4d09be9e2 Move the pch input file in Inputs folder. 2014-10-01 14:24:12 +02:00
Vassil Vassilev
a8ccf3468c Add a test exposing an issue with the unloading of inlined functions coming from a pch/pcm. 2014-10-01 14:24:12 +02:00
Vassil Vassilev
f3e4d96ffc Remove the pch. It is generated by the test. 2014-10-01 14:24:11 +02:00
Vassil Vassilev
766030c1e0 Add test for unloading of vtables coming from a pch/pcm. 2014-09-30 17:34:12 +02:00
Vassil Vassilev
f8b513b63a Remove obsolete test. It meant to test autoloading based on ctags, which is gone now. 2014-09-28 22:45:04 +02:00
Vassil Vassilev
13687cd986 Mark as XFAIL until Axel fixes it. 2014-09-28 17:02:06 +02:00
Axel Naumann
8c4f91bfe8 Add test for ROOT-5467. 2014-09-26 16:54:02 +02:00
Vassil Vassilev
122233ada6 Do not display suggestions only for ROOT. 2014-09-19 14:05:15 +02:00
Vassil Vassilev
dba2f39ff4 Print only annotate attr until type_visibility printing is fixed. 2014-09-15 14:12:06 +02:00
Vassil Vassilev
c0321e417e Test passes. 2014-09-04 11:03:05 +02:00
Vassil Vassilev
d303a43760 Add expected warning. 2014-09-03 12:03:03 +02:00
Vassil Vassilev
efa445eb72 Reenable test. 2014-08-23 15:05:01 +02:00
Vassil Vassilev
eda6bc1949 Improve and reenable test. 2014-08-21 17:26:02 +02:00
manasij7479
9b17f43f05 Enable callback in Interpreter, change test to use metacommand 2014-08-21 17:07:01 +02:00
Vassil Vassilev
cbdc92cedb Disable tests until the multiplexing interpreter callback comes. 2014-08-20 16:53:04 +02:00
Vassil Vassilev
6bbc4fa200 Disable feature until we get the upgrade settled. 2014-08-15 14:53:01 +02:00
Vassil Vassilev
212259918a Implement continuation for #if* #endif. 2014-08-15 12:34:00 +02:00
Vassil Vassilev
a415711407 Implement a shebang support in cling. 2014-08-14 14:56:43 +02:00
Vassil Vassilev
afaf997555 We cannot pass in a 'proper' source location, thus we cannot use -verify. 2014-08-14 14:56:43 +02:00
Vassil Vassilev
f14fbd2b78 Make sure no diags are emitted. 2014-08-14 14:56:43 +02:00
manasij7479
282ce06530 Recheck if top level decl, workaround test problem by printing pass in a loop 2014-08-14 14:56:43 +02:00
manasij7479
3c260f9e4a New log file name format, and skip function templates with default function arguments 2014-08-14 14:56:43 +02:00
Vassil Vassilev
7238b2eb7b Autoloading is enabled by default. 2014-08-14 14:56:42 +02:00
manasij7479
7b99ddcfa1 Skip decls using names from defs like typedef struct {} structName 2014-08-14 14:56:40 +02:00
Vassil Vassilev
dd554c2d6e Use #include instead of real files.
If we use real files cling would .x them and run a function named after the file.
In our case it is missing and would issue useless warnings.
2014-08-14 14:56:40 +02:00
Vassil Vassilev
8a8651a8d0 Implement diagnostic report in missing .x function to call. 2014-08-14 14:56:40 +02:00
Vassil Vassilev
5d6297b821 Adapt to the new invocation. 2014-08-14 14:56:40 +02:00
Vassil Vassilev
7ecb829baa Move the test at its right place 2014-08-14 14:56:40 +02:00
Vassil Vassilev
c51df6e215 The invocation changed, follow the changes. 2014-08-14 14:56:40 +02:00
Vassil Vassilev
e0874ff6a4 Improve the STL test. Now we can reenable it. 2014-08-14 14:56:39 +02:00
Vassil Vassilev
a1640388a4 On .x try calling the specially named function only if it exists. 2014-08-14 14:56:39 +02:00
manasij7479
38b773ad3e Simple test for Standard Library headers, and a few more workarounds 2014-08-14 14:56:38 +02:00
Vassil Vassilev
a3058bf045 Disable #inclusion of the generated fwd decl headers. 2014-08-14 14:56:38 +02:00
Vassil Vassilev
14fecdd942 Try #include the generated files by separate instance. 2014-08-14 14:56:38 +02:00
Vassil Vassilev
ac4ab27781 Reduce the iteration to only STL (at least on Ubu is the first include path.) 2014-08-14 14:56:37 +02:00
Vassil Vassilev
bacc8b6f08 Remove debug printout. Run in verify mode. 2014-08-14 14:56:37 +02:00
Vassil Vassilev
0065df1842 Test the fwd decl generator with all headers in the include path. 2014-08-14 14:56:37 +02:00
Vassil Vassilev
03f4edd3c1 Do not print the inherited default arguments. 2014-08-14 14:56:36 +02:00
Vassil Vassilev
f65296420e Put back the XFAIL. 2014-08-14 14:56:35 +02:00
Vassil Vassilev
53d7da9b75 No need of undo anymore. 2014-08-14 14:56:35 +02:00
Vassil Vassilev
d8f6659dcc Improve support for enum redeclaration. 2014-08-14 14:56:35 +02:00
Vassil Vassilev
ba9ed46a99 Tweak test expectations to match the new pretty printing. 2014-08-14 14:56:34 +02:00
Axel Naumann
11d315a22b Also print structs; add test. 2014-08-14 14:19:03 +02:00
Philippe Canal
576ca3ca96 Remove trailing spaces 2014-08-13 16:08:36 +02:00
Vassil Vassilev
a833661f08 Fix failing test. 2014-07-25 13:18:01 +02:00
manasij7479
662262e3ac Rename SetAutoloadCallback to EnableAutoloading 2014-07-22 14:52:04 +02:00
manasij7479
03e5ef7668 Prevent printing non-fixed enums Remove skipping of system headers Also, do not print default template arguments if they do not have a name. 2014-07-22 14:52:04 +02:00
manasij7479
a812b2cd1d Added a function to attach the AutoloadCallback automatically 2014-07-22 14:52:03 +02:00
manasij7479
083ab88d81 Modified test to include a function with a default arg 2014-07-22 14:52:03 +02:00
manasij7479
e7a196dcbd Transformation-Callback Pipeline for Decls needing special handling (when defining after being forward declared.)
New state in Interpreter (AutoloadingStateInfo) containing a map.
AutoloadingTransform adapted to push required decls into this map.
AutoloadCallback adapted to be called when a file is included (but before being parsed)
(done by enabling PPCallbacks and overriding InclusionDirective method)
m_PPCallbacks changed from OwningPtr to a normal pointer as an workaround for double free bug.
Default template arguments as a POC example usage of this pileline.

Test:
AutoForwarding.C now passes because of this commit.

Extra:
Re-enabled the printing of class template default arguments when generating fwd declarations.
Forward declprinter now looks up the SourceManager for file name instead of directly printing the Argument.
2014-07-22 14:52:02 +02:00
manasij7479
2e3e929a41 Skip functions and vars with nested types and new failing enum tests 2014-07-22 14:52:02 +02:00
Axel Naumann
41d9497052 Test that #pragma diagnoistics does not cause problems. 2014-07-01 14:44:04 +02:00
Vassil Vassilev
1fd7010509 Remove the XFAIL, the test doesn't fail anymore. 2014-06-24 11:26:57 +02:00
Manasij Mukherjee
f474d63079 Generation of forward declarations of top level decls in an input file.
Consists of:
  ForwardDeclPrinter, adapted from clang::DeclPrinter
  Interpterer::GenerateAutoloadingMap for invoking the functionality
  It has hardcoded checks to prevent ForwardDeclPrinter from visiting decls from
standard library files. This restriction will be lifted after the
issues specifyed in the tests are fixed.
  Test cases for code which FowrardDeclPrinter can not deal with properly
2014-06-23 14:37:03 +02:00
Vassil Vassilev
de2d2ee714 Adapt tests for the newly produced diagnostics. 2014-06-10 15:24:01 +02:00
manasij7479
983abbe17b split out failing stl test 2014-06-10 15:24:01 +02:00
manasij7479
297d005617 other fixes 2014-06-10 15:24:01 +02:00
manasij7479
236172318f removed ctags tests 2014-06-10 15:24:01 +02:00
Vassil Vassilev
f5250400d4 Remove the junk I accidentally committed. 2014-06-05 17:38:59 +02:00
manasij7479
46d8d76d80 modified tests
(cherry picked from commit 77316a2838c5037feff8091bb5c0919bc59d6b16)
2014-06-04 10:06:03 +02:00
manasij7479
0a0da4f26d enum test for template
(cherry picked from commit ce717aac63c7bd29e836106e255df98b23c4fdb3)
2014-06-04 10:06:02 +02:00
manasij7479
c7e56b7ea1 enum test for C++11 enum class, does not have C enums yet
(cherry picked from commit 9b7d0c5260f79b321b8b21b3c19da3e8c507aa11)
2014-06-04 10:06:01 +02:00
manasij7479
cee01f1a13 added a function and a trait util from stl
(cherry picked from commit 2ea8127e629ee26a48bbaeda8da935dbe04d7ebe)
2014-06-04 10:06:00 +02:00
manasij7479
58a58d2ed1 added some stl forward decls
(cherry picked from commit 365737c218defce09bbceca2119f396236564c99)
2014-06-04 10:06:00 +02:00
manasij7479
01a4bf5e5b Initial tests for verifying forward declarations
(cherry picked from commit c9b5a07d5cd83100862e067ccff189e10c666f9b)
2014-06-04 10:06:00 +02:00
Vassil Vassilev
56b5dc86dd Obey coding rules and indentation. 2014-06-04 09:20:15 +02:00
manasij7479
024b16df11 Init TagsExtension Module, for extending cling to provide interactive hints
AutoloadCallback: Implementing InterpreterCallbacks to attach the module to cling
   The main focus is on overriding LookupObject so that the information about
   lookup failures are obtained from clang.
   The type of the name is not taken into consideration for now.

TagManager: To manage and lookup information from various sorts of tag files.
   Currently a TagManager object is owned by the callback system.
   This may change in future.

Wrapper: As a base class for handling particular types of tagfiles.
   The TagManager maintains a container of Wrappers.

CtagsFileWrapper: Implementing a wrapper for ctags.
   This class is responsible for generating a tagfile from a given path or list of files.
   It also performs lookups in the file generated by it.

And a few simple file system utils to complement llvm::sys::fs and path utilities
2014-06-04 09:20:14 +02:00
Axel Naumann
b91c987027 Fix value printing for functions. Needs test! 2014-05-28 18:09:57 +02:00
Axel Naumann
39ed28c03e Void has no address. 2014-05-26 17:37:57 +02:00
Vassil Vassilev
6e9cd68cb2 Construct a library call example. The full reflection-based call still to come. 2014-05-23 12:36:01 +02:00
Vassil Vassilev
6d8b154f7f Fix broken by constrution test. 2014-05-23 12:36:01 +02:00
Vassil Vassilev
73752eff5e Bring to more up-to-date an xfailure. 2014-05-23 12:36:01 +02:00
Vassil Vassilev
ec31eb9db8 Test value printing of template constructs 2014-05-22 11:13:55 +02:00
Bertrand Bellenot
2b34bf819e Update cling test using .help to match the new help format 2014-05-21 17:18:57 +02:00
Vassil Vassilev
c86fbc27b9 Rewire the dumping on cling::Value to its new implementation.
Dump cling::Value within setNoAlloc routines because this is its lifespan,
otherwise gets deleted if nobody requested it. I.e it was created only for
value printing purposes.

Dump cling::Value outside setWithAlloc because the actual value is not put inside
until the call to ::new finishes, thus we need to do it outside, i.e in EvaluateInternal.

Switch on the ValueExtraction synthesizer even when 'just' value printing. We
depend on it. Must be factored out properly in one class.

Stop attaching the value printing template magic, which didn't work in some cases.

Update the ref file, because now there is better type information.

Adapt the user-defined printout functions (TDatime).
2014-05-18 18:08:58 +02:00
Vassil Vassilev
250dbcf655 Collapse the tests into one. 2014-05-18 18:08:58 +02:00
Philippe Canal
d1e545b60d In Partial desugar add support for array type 2014-05-14 09:03:56 +02:00
Vassil Vassilev
cefb472b5f Update the test to more generically 'detect' the version. 2014-05-09 15:28:06 +02:00
Lukas Vacek
1346b05af4 Adding test for ROOT-6244 (test_exec_in_same_dir.C) 2014-05-02 19:01:01 +02:00
Vassil Vassilev
9b4ea193c0 If cling::Value is provided turn result evaluation on. 2014-04-14 09:09:01 +02:00
Axel Naumann
628618f2b9 Add test for copy ctor and dtor in Value for array-of-structs. 2014-04-11 09:00:01 +02:00
Vassil Vassilev
d1a416ddc0 When variadic return stmt doesn't have a return value, invalidate the calculation of the last expr for evaluation.
In the same cases we still need to synthesize the setValueNoAlloc, to initialize
the cling::Value to void.
2014-04-04 09:42:07 +02:00
Vassil Vassilev
c868ddfd49 In cases of cling::Value reuse we need to update its settings even if we evaluated void expression. 2014-04-02 16:56:58 +02:00
Axel Naumann
d00d9e8d54 Simplify; adapt to new Value. 2014-04-01 18:31:58 +02:00
Vassil Vassilev
234bfb7770 Simplify some of the changes due to the new diag mapping. 2014-04-01 17:09:58 +02:00
Vassil Vassilev
ab58d03cba Add known failures section. 2014-03-31 16:53:55 +02:00
Vassil Vassilev
8b485436fb Preprocess the file before looking for expected-error substrings. This helps in tests which have multiple RUN lines and define a macro in them. 2014-03-31 16:53:55 +02:00
Axel Naumann
bbf4a3588f Update to XCode 5.1; e.g. ignore type of std::string::c_str(). 2014-03-31 15:15:57 +02:00
Vassil Vassilev
68221520fc Silence a warning. 2014-03-31 14:03:09 +02:00
Vassil Vassilev
14dc0c1c99 Silence a warning. 2014-03-31 14:03:09 +02:00
Vassil Vassilev
666437108e Replace .U with .undo 2014-03-31 14:03:09 +02:00
Vassil Vassilev
40195aa864 Cosmetics. 2014-03-31 14:03:06 +02:00
Vassil Vassilev
d7d4674f4e Increase verbosity of the output 2014-03-31 14:03:05 +02:00
Vassil Vassilev
2f9ba97a53 We need internal isystem. 2014-03-31 14:03:05 +02:00
Vassil Vassilev
0210c101f4 Escape -x flags passed in as invocation. 2014-03-31 14:03:03 +02:00
Vassil Vassilev
c65f5bbba6 Use proper regexp 2014-03-27 11:18:57 +01:00
Vassil Vassilev
9af7ee2640 Actual optional regex syntax. 2014-03-24 15:26:56 +01:00
Vassil Vassilev
80a0e1e56e C++11 noexcept op. 2014-03-24 14:25:58 +01:00
Vassil Vassilev
c6544c49f9 Update test. 2014-03-24 14:25:57 +01:00
Philippe Canal
93ce42bdc3 Preliminary support for template alias.
GetPartiallyDesaguredType now desugar template alias
but does not yet properly propagate the opaque typedef
and thus:

  template <typename T> using myvector = std::vector<T>;
  myvector<Double32_t> vd32d;

  template<class T> using ptr = T*;
  ptr<Double32_t> p3;

Both currently result in the Double32_t being ignored.
2014-03-21 16:57:07 +01:00
Philippe Canal
45895aec23 No longer hide the compiler detail.
The partial desugaring (part of normalization) now strips a typedef
even when it original from std and points to compiler details (__gnu_cxx, etc.).

The cost of this convenience was the fact the same entity could have different
'name' and thus different class even-though they were supposed to be strictly
equivalent. i.e. depending on the way to get to the class it could be name
vector<int*>::iterator or __gnu_cxx::iterator<int*> or std::iterator<int*>.

This different from the case where we have a strictly bidirectional equivalent
between the class and its unique typedef (yes, we are talking about you std::string).

This also different from the case where there is a semantic difference between
the two possible name.  I.e. where an opaque typedef is used.  For example,
vector<Double32_t> and vector<double> and where the 'way' to get to the type[name]
is relevant.
2014-03-21 16:57:07 +01:00
Axel Naumann
2699d27626 Add test for ROOT-6124. 2014-03-18 09:12:02 +01:00
Axel Naumann
73a285d69a Add tests for ROOT-6137. 2014-03-14 17:31:02 +01:00
Vassil Vassilev
b9a4d063d1 Reduce the noise in compareState. 2014-03-14 10:52:29 +01:00
Vassil Vassilev
f6f4c707d4 Add a dead code removal pass. The test is expected to succeed now.
Removing a GlobalValue from the module might make other values (referenced only
by the one being removed) available for removal. Those should go as well. The
initial implementation is a bit greedy - it removes more: i.e dtors because they
are not referenced (because IncrementalExecutor takes care of them in an custom
way)
2014-03-14 10:52:29 +01:00
Axel Naumann
ed1069786f Improve version string; adapt test. 2014-03-05 09:46:09 +01:00
Axel Naumann
e784149c9b Update tests to new clang output. 2014-03-03 19:11:05 +01:00
Axel Naumann
40be9385f3 From Cristina: tests redirection. 2014-03-02 19:45:00 +01:00
Vassil Vassilev
c66118f2e2 Make the test xfailing because we don't handle .str removal and deferred decls removal. 2014-02-27 12:49:13 +01:00
Vassil Vassilev
150231c357 Run only dtors of the unloaded entities. 2014-02-27 12:49:11 +01:00
Axel Naumann
574b7751f9 Test the behavior of the ValueExtractionSythesizer for objects.
Still missing: arrays incl arrays of objects.
2014-02-26 09:22:05 +01:00
Axel Naumann
9c73790d79 Test decl extraction of const enum.
And uncover a new bug: k2 is not visible, now ROOT-6095.
2014-02-19 15:59:01 +01:00
Axel Naumann
efa8f37cd4 long double has "L" suffix. 2014-02-19 15:34:56 +01:00
Vassil Vassilev
02a9f05fe0 Follow the change ExecutionContext -> IncrementalExecutor. 2014-02-19 15:01:03 +01:00
Axel Naumann
c78aa3b7fb Test value printing of a long double. 2014-02-19 14:55:00 +01:00
Axel Naumann
6b3e713217 Test evaluation of long double. 2014-02-19 14:55:00 +01:00
Vassil Vassilev
e92088a41e If RHS is dependent - skip value extraction. Add a testcase for auto vars. 2014-02-19 14:22:58 +01:00
Axel Naumann
2a58b82ebe Update tests to new interfaces. 2014-02-19 12:55:00 +01:00
Vassil Vassilev
9749af417c The test should be run on 32 bit finally. 2014-02-18 17:22:59 +01:00
Vassil Vassilev
460b8b43b1 We have more accurate results so adjust the test. 2014-02-18 17:22:59 +01:00
Vassil Vassilev
980a1813cf typo. 2014-02-18 17:22:59 +01:00
Vassil Vassilev
c963d9f520 Add var returns test case. 2014-02-18 17:22:58 +01:00
CristinaCristescu
0b3a2d5ef0 Correct comment. 2014-02-18 17:08:57 +01:00
CristinaCristescu
7605c85f5c Fix Cling Regression test. 2014-02-18 17:08:57 +01:00
Axel Naumann
fae0d4037f Follow changes in llvm/clang. 2014-02-18 08:29:38 +01:00
Vassil Vassilev
f34076fffc Send the output of grep to /dev/null 2014-02-12 11:00:59 +01:00
Vassil Vassilev
da37422d23 Ignore -o -, this is by default what we do in cling 2014-02-12 11:00:59 +01:00
Vassil Vassilev
04304014ca Run clang with -print-file-name=include, seems that is needed by clang's testsuite. 2014-02-12 11:00:59 +01:00
Vassil Vassilev
5933b67862 Improve debugging look and feel. 2014-02-10 11:20:55 +01:00
CristinaCristescu
091a2aabaf Add correct test for unanamed decls for cling. 2014-02-07 23:12:58 +01:00
CristinaCristescu
aadc2db22c Add test for unnamed decls for cling. 2014-02-07 23:12:58 +01:00
Vassil Vassilev
2c2ada407e XFAIL clang's testsuite for now. 2014-02-06 14:57:52 +01:00
Vassil Vassilev
0055f5b14e Adjust to the test with the correct vars. 2014-02-06 14:50:58 +01:00
Vassil Vassilev
0fec137d95 Add a test that loads every clang test and unloads it 2014-02-06 14:50:58 +01:00
Axel Naumann
d6dfcf82a8 Fix const char * regexp. 2014-01-28 18:59:54 +01:00
Axel Naumann
00e3fd5e7c libc++ fixes, e.g. c_str() returns const_pointer. 2014-01-28 18:21:55 +01:00
Axel Naumann
6e4f29775c Fix non-MacOS platform.mac_ver(). 2014-01-28 15:42:52 +01:00
Axel Naumann
8efd17d0e6 On MacOS 10.9 our clang will not find the stdlib. Use the XCode's clang instead. 2014-01-28 15:07:55 +01:00
Axel Naumann
dcf31e7e39 Skip this test; it is unreliable. 2014-01-23 11:33:54 +01:00
Axel Naumann
10464f6fe1 Add test for recursive static init. 2014-01-22 15:59:56 +01:00
Axel Naumann
4f07ffa888 Refer to license in C files. 2014-01-07 12:02:58 +01:00
Axel Naumann
8aedeca69c Refer to license in CMake files. 2014-01-07 12:02:58 +01:00
Axel Naumann
d240bd5de8 Refer to license in test and demo files. 2014-01-07 12:02:58 +01:00
Axel Naumann
44481ace1e Fix license; remove $Id$ version. 2014-01-07 11:14:04 +01:00
Axel Naumann
5da6e646a5 Correct licenses in Makefiles. 2014-01-07 11:13:56 +01:00
Axel Naumann
47475c9934 Do not run the test at all on 32bit: it might or might not fail. 2013-12-17 15:29:49 +01:00
Axel Naumann
51f03371e1 Aggregate returns do not work on 32bit; see ROOT-5860. 2013-12-17 13:54:53 +01:00
Axel Naumann
020af968f0 Resolve Elab and TemplSpecTypes; use short name for dtor; test (ROOT-5839). 2013-12-12 21:46:51 +01:00
Vassil Vassilev
318427ba99 Reset the diagnostic client on recovery too. 2013-12-12 14:44:53 +01:00
Axel Naumann
b0fe13d878 Test lifetime handling of StoredValue. 2013-12-11 12:14:52 +01:00