diff options
| author | Sami Shalayel <sami.shalayel@qt.io> | 2025-04-04 10:32:53 +0200 |
|---|---|---|
| committer | Sami Shalayel <sami.shalayel@qt.io> | 2025-04-11 15:50:24 +0200 |
| commit | c735d3edaa4594b214b52ca6219516cbd4f31138 (patch) | |
| tree | 0610f12fa4f899745a95bd091d9e19fbf39f28f3 /src/qmlcompiler/qqmljslintercodegen.cpp | |
| parent | 57a638d6640e5a8dbfbb0d2d488d4a32985e56ac (diff) | |
qqmljslintercodegen: don't ignore the results from run()
The passes currently don't modify BasicBlocksAndAnnotations, but I think
its nice to not ignore their return value, in case they start modifying
annotations or basic blocks in the future.
Change-Id: I4edcf6958a9a3cf65c91c5389fb42a1dd72d35db
Reviewed-by: Olivier De Cannière <olivier.decanniere@qt.io>
Diffstat (limited to 'src/qmlcompiler/qqmljslintercodegen.cpp')
| -rw-r--r-- | src/qmlcompiler/qqmljslintercodegen.cpp | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/src/qmlcompiler/qqmljslintercodegen.cpp b/src/qmlcompiler/qqmljslintercodegen.cpp index 8629281849..d4afc342e0 100644 --- a/src/qmlcompiler/qqmljslintercodegen.cpp +++ b/src/qmlcompiler/qqmljslintercodegen.cpp @@ -103,24 +103,24 @@ void QQmlJSLinterCodegen::analyzeFunction(const QV4::Compiler::Context *context, return; if (!m_logger->currentFunctionHasCompileError()) { - QQmlJSShadowCheck shadowCheck(m_unitGenerator, &m_typeResolver, m_logger, - blocksAndAnnotations.basicBlocks, - blocksAndAnnotations.annotations); - shadowCheck.run(function); + blocksAndAnnotations = QQmlJSShadowCheck(m_unitGenerator, &m_typeResolver, m_logger, + blocksAndAnnotations.basicBlocks, + blocksAndAnnotations.annotations) + .run(function); } if (!m_logger->currentFunctionHasCompileError()) { - QQmlJSStorageInitializer initializer(m_unitGenerator, &m_typeResolver, m_logger, - blocksAndAnnotations.basicBlocks, - blocksAndAnnotations.annotations); - initializer.run(function); + blocksAndAnnotations = QQmlJSStorageInitializer(m_unitGenerator, &m_typeResolver, m_logger, + blocksAndAnnotations.basicBlocks, + blocksAndAnnotations.annotations) + .run(function); } if (!m_logger->currentFunctionHasCompileError()) { - QQmlJSStorageGeneralizer generalizer(m_unitGenerator, &m_typeResolver, m_logger, - blocksAndAnnotations.basicBlocks, - blocksAndAnnotations.annotations); - generalizer.run(function); + blocksAndAnnotations = QQmlJSStorageGeneralizer(m_unitGenerator, &m_typeResolver, m_logger, + blocksAndAnnotations.basicBlocks, + blocksAndAnnotations.annotations) + .run(function); } } |
