Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Utilities
Kate
Commits
e0af8424
Commit
e0af8424
authored
Dec 29, 2021
by
Volker Krause
Browse files
Adapt to QChar no longer being implicitly constructable from an int
parent
f174f6c0
Pipeline
#115875
passed with stage
in 5 minutes
Changes
1
Pipelines
3
Hide whitespace changes
Inline
Side-by-side
addons/symbolviewer/cpp_parser.cpp
View file @
e0af8424
...
...
@@ -101,7 +101,7 @@ void KatePluginSymbolViewerView::parseCppSymbols(void)
macro
=
3
;
}
if
(
macro
==
3
)
{
if
(
cl
.
at
(
j
)
>=
0x20
)
{
if
(
cl
.
at
(
j
)
>=
QChar
(
0x20
)
)
{
stripped
+=
cl
.
at
(
j
);
}
if
(
cl
.
at
(
j
)
==
QLatin1Char
(
' '
)
||
cl
.
at
(
j
)
==
QLatin1Char
(
'\t'
)
||
j
==
cl
.
length
()
-
1
)
{
...
...
@@ -248,7 +248,7 @@ void KatePluginSymbolViewerView::parseCppSymbols(void)
}
if
(
comment
!=
2
&&
comment
!=
3
)
{
if
(
block
==
1
&&
graph
==
0
)
{
if
(
cl
.
at
(
j
)
>=
0x20
)
{
if
(
cl
.
at
(
j
)
>=
QChar
(
0x20
)
)
{
stripped
+=
cl
.
at
(
j
);
}
if
(
cl
.
at
(
j
)
==
QLatin1Char
(
'('
))
{
...
...
@@ -283,7 +283,7 @@ void KatePluginSymbolViewerView::parseCppSymbols(void)
if
((
cl
.
at
(
j
)
==
QLatin1Char
(
'{'
)
&&
structure
==
false
&&
cl
.
indexOf
(
QLatin1Char
(
';'
))
<
0
)
||
(
cl
.
at
(
j
)
==
QLatin1Char
(
'{'
)
&&
structure
==
false
&&
cl
.
indexOf
(
QLatin1Char
(
'}'
))
>
j
))
{
stripped
.
replace
(
0x9
,
QLatin1String
(
" "
));
stripped
.
replace
(
QChar
(
0x9
)
,
QLatin1String
(
" "
));
if
(
m_func
->
isChecked
())
{
QString
strippedWithTypes
=
stripped
;
if
(
!
m_typesOn
->
isChecked
())
{
...
...
@@ -294,8 +294,8 @@ void KatePluginSymbolViewerView::parseCppSymbols(void)
stripped
=
stripped
.
mid
(
stripped
.
indexOf
(
QLatin1String
(
"::"
))
+
2
);
}
stripped
=
stripped
.
trimmed
();
while
(
stripped
.
indexOf
(
0x20
)
>=
0
)
{
stripped
=
stripped
.
mid
(
stripped
.
indexOf
(
0x20
,
0
)
+
1
);
while
(
stripped
.
indexOf
(
QChar
(
0x20
)
)
>=
0
)
{
stripped
=
stripped
.
mid
(
stripped
.
indexOf
(
QChar
(
0x20
)
,
0
)
+
1
);
}
while
((
stripped
.
length
()
>
0
)
&&
((
stripped
.
at
(
0
)
==
QLatin1Char
(
'*'
))
||
(
stripped
.
at
(
0
)
==
QLatin1Char
(
'&'
))))
{
stripped
=
stripped
.
right
(
stripped
.
length
()
-
1
);
...
...
@@ -337,7 +337,7 @@ void KatePluginSymbolViewerView::parseCppSymbols(void)
stripped
.
clear
();
break
;
// Avoid an infinite loop :(
}
if
(
structure
==
true
&&
cl
.
at
(
j
)
>=
0x20
)
{
if
(
structure
==
true
&&
cl
.
at
(
j
)
>=
QChar
(
0x20
)
)
{
stripped
+=
cl
.
at
(
j
);
}
}
// BLOCK 2
...
...
@@ -385,7 +385,7 @@ void KatePluginSymbolViewerView::parseCppSymbols(void)
// break;
continue
;
}
if
(
cl
.
at
(
j
)
>=
0x20
)
{
if
(
cl
.
at
(
j
)
>=
QChar
(
0x20
)
)
{
stripped
+=
cl
.
at
(
j
);
}
}
// BLOCK 4
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment