Skip to content

Commit 0ba4466

Browse files
committed
CppEditor: Deprecate "assign to local" quickfix
... in favor of clangd's "Extract Variable" tweak. As of llvm/llvm-project#112525, this functionality should be fully covered by clangd. Task-number: QTCREATORBUG-9363 Task-number: QTCREATORBUG-9578 Change-Id: I00ce996ef37b26152d93ed91fa5d1ea69e619618
1 parent 594edc4 commit 0ba4466

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/plugins/cppeditor/quickfixes/assigntolocalvariable.cpp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,8 +123,13 @@ class AssignToLocalVariableOperation : public CppQuickFixOperation
123123
//! Assigns the return value of a function call or a new expression to a local variable
124124
class AssignToLocalVariable : public CppQuickFixFactory
125125
{
126-
#ifdef WITH_TESTS
127126
public:
127+
AssignToLocalVariable()
128+
{
129+
setClangdReplacement({20});
130+
}
131+
132+
#ifdef WITH_TESTS
128133
static QObject *createTest();
129134
#endif
130135

0 commit comments

Comments
 (0)