Files
codeql/python/ql/test/3/extractor-tests/fstrings3.6/Formatted.ql
Taus 1c68c987b0 Python: Change all remaining occurrences of StrConst
Done using
```
git grep StrConst | xargs sed -i 's/StrConst/StringLiteral/g'
```
2024-04-22 12:00:09 +00:00

16 lines
403 B
Plaintext

import python
from FormattedValue val, string format, string typeconv
where
(
typeconv = val.getConversion()
or
not exists(val.getConversion()) and typeconv = " "
) and
(
format = val.getFormatSpec().getValue(0).(StringLiteral).getText()
or
not exists(val.getFormatSpec()) and format = ""
)
select val.getLocation().getStartLine(), val, format, val.getValue(), typeconv