IF YOU WOULD LIKE TO GET AN ACCOUNT, please write an
email to Administrator. User accounts are meant only to access repo
and report issues and/or generate pull requests.
This is a purpose-specific Git hosting for
BaseALT
projects. Thank you for your understanding!
Только зарегистрированные пользователи имеют доступ к сервису!
Для получения аккаунта, обратитесь к администратору.
Related to the discussion in ROOT-5971 (see https://sft.its.cern.ch/jira/browse/ROOT-5971),
this commit improves the situation by diagnosing the shadowing of declarations
in the `std` namespace.
In summary, given that ROOT issues an implicit `using namespace std;` and due to
the way `SemaLookup` works, decls that shadow something in the `std` namespace
cannot be referenced without using their fully-qualified name, i.e. `::xxx`.
Thus, we need to emit a warning for that case.
This member provides additional information about the context in which parsing
occurs.
In particular, the `kInputFromFile` and `kIFFLineByLine` flags allow to tell
whether a sequence of calls to `Interpreter::process()` is issued from
`MetaProcessor::readInputFromFile()` for the contents of an external file.
Declarations extracted by DeclExtractor, regardless of their type, should be
moved to the parent declaration context (be it the `TranslationUnitDecl` or a
`NamespaceDecl` if DefinitionShadower is enabled).
This prevents the following situation:
```
root [] struct X {} foo
(struct X &) @0x7f545a5ff018
root [] .stats asttree
|-NamespaceDecl 0x5647ecc93780 <<invalid sloc>> <invalid sloc> __cling_N50 inline
| |-VarDecl 0x5647ecc89f10 <ROOT_prompt_0:1:1, col:13> col:13 used foo 'struct X':'X' callinit
| | `-CXXConstructExpr 0x5647ecc8a420 <col:13> 'struct X':'X' 'void () noexcept'
| `-FunctionDecl 0x5647ecc89bc8 <input_line_8:1:1, ROOT_prompt_0:3:1> input_line_8:1:6 __cling_Un1Qu30 'void (void *)'
...
|-CXXRecordDecl 0x5647ecc89c98 <line:1:1, col:11> col:8 struct X definition
```
`MetaProcessor::awaitingMoreInput()` returns whether the collected input is
incomplete, either because it contains unbalanced braces or we found a
backslash-newline (the last seen token is a `\`).
Part of a patch series to fix ROOT-5219.
Co-authored-by: Axel Naumann <Axel.Naumann@cern.ch>
`InputValidator::getLastResult()` returns the validation result of the last call
to `validate()`.
This will be used to implement `MetaProcessor::awaitingMoreInput()`.
Part of a patch series to fix ROOT-5219.
This reverts commit eb52895d22aaad0a88d47b8e7bb18c7f47ff35be.
As discussed, we should try to make clang parse input containing solely a
function-style cast (e.g. `bool(i)`) as an expression instead of a declaration.
In the interim, this patch is reverted to silence unwanted warnings in
third-party code.
The PR https://github.com/root-project/root/pull/9695 will also be closed.
This was an oversight in commit 34590aeef4: After fixing the handler
blocks, the code needs to create new CXXCatchStmts to eventually
construct the CXXTryStmt.
Fixes#9664
As the JIT does not provide debug symbols (yet), users see
only the call frames invoking the JIT - which is not helpful
as it is unrelated to their code.
We can turn this back on (possibly restricting to JIT frames)
once we emit debug symbols in the JIT.
This reverts commit 0cdfa69f216854d7319a6a31a61021a1e5ac45de.
We need to hide json includes: modules cannot cope with them, and it introduces a runtime requirement to find json.
`RunFunction()` might trigger unloading of `lastT`, so store its setting
for "want value printing" in a local variable before calling RunFunction().
Fixes valgrind complaining about `./stressInterpreter` which is reloading
the "outer" stressInterpreter.cxx from inside `RunFunction()`.
When determining whether a weak symbol was already emitted (and its
subsequent definition can thus be replaced by a declaration) look
for emitted symbols in the symbol table and the in-process symbols,
instead of possibly generating symbols through the JIT. This prevents
symbols being emitted that refer into
IncrementalExecutor::m_PendingModules elements that have since been
removed.
The case of `ExprAddresses == nullptr` seems to be naturally handled in the
lines below. Therefore, removing this assertion -as discussed with vvassilev.
Closes issue #8389.
This is now hit for variables on Windows (which don't see the GlobalVariable case).
Before the `#ifndef WIN32`, this case was not hit by roottest, neither on Windows
nor macOS nor Linux - so the coverage of "make it a declaration" is good.
Fixes test failures (crashes) in
projectroot.test.test_stressiterators_interpreted
projectroot.roottest.cling.dict.roottest_cling_dict_assertTmpltDefArgCtor
projectroot.test.test_stresshistogram_interpreted
projectroot.roottest.root.meta.roottest_root_meta_runnamespace_auto
Instead of suppressing the emission of weak symbols that have an existing
in-process definition, remove the definition of the weak symbol from the
module. This prevents relocation "surprises" as seen e.g. on Apple M1, where
weak symbol definitions are expected to be found within the module, and
relocations are thus expected to be local. By removing the definition, the
symbol becomes a reference (declaration) and relocation will work as for any
non-local symbol.
Thus also reduces the amount of duplicate work, as in-process weak symbols
will now be suppressed early.
* [cling][windows] change compiler flags
- Set the `-std:c++14` / `-std:c++17` flag depending on the version of Visual Studio (only if building outside ROOT)
- Split the one line exports in three lines to fix a potential issue with Ninja on Windows (missing a white space between each `/EXPORT:` specifier)
* Add a forgotten `endif()`
These changes enable the replacement of the default DiagnosticConsumer provided
by CIFactory. Concretely, two member functions have been added to the
Interpreter class:
- replaceDiagnosticConsumer(): replaces the default CIFactory-provided DiagnosticConsumer.
- hasReplacedDiagnosticConsumer(): returns whether the default diagnostic
consumer has been replaced.
Replace implementation of `InputValidator::validate()` by simpler, more
maintainable code that also fixes ROOT-9202.
The previous implementation was unable to properly handle line continuation
after ',' or '\'. Specifically, it skipped over non-punctuation tokens,
entering continuation mode even if ',' or '\' were not the last tokens in the
input, e.g. `int a, b` or 'int a \ b'.
Fixes ROOT-9202.
This commit includes the following changes to MetaLexer:
- Update `MetaLexer::Lex()` to return `/*` (tok::l_comment), `*/` (tok::r_comment),
and `<` (tok::less) as tokens.
- Added `MetaLexer::ReadToEndOfLine()` function: consume input until `\r` or `\n`.
- Added `MetaLexer::RAII`, a RAII object that saves/restores the current position.
This new release includes some improvements:
* Extended array support
* Add cmake variables to control the locations where find_package discovers LLVM and Clang: `LLVM_CONFIG_EXTRA_PATH_HINTS` and `Clang_CONFIG_EXTRA_PATH_HINTS` respectively.
See more at: https://github.com/vgvassilev/clad/blob/v0.9/docs/ReleaseNotes.md
Some libraries are layered can depend on other libraries on a private paths.
That is, libA can depend on libB which is neither on the LD_LIBRARY_PATH nor
on a known system path. The posix linker injects "variables" such as @rpath
which is expanded at link time to resolve the libraries on a relative path.
Prior to this patch, cling's Dyld-based symbol resolution could not trace down
such cases causing failures in symbol resolution when a symbol is only defined
in libB (a private library).
This patch implements the basic posix linker substitutions allowing cling's
Dyld-based symbol resolution implementation to follow more closely the linker
rules.
Kudos Alexander Penev (@alexander-penev).