151 friend class TestToken;
162 eNumber, eString, eChar,
eBoolean, eLiteral, eEnumerator,
163 eArithmeticalOp, eComparisonOp, eAssignmentOp, eLogicalOp, eBitOp, eIncDecOp, eExtendedOp,
183 update_property_info();
190 void concatStr(std::string
const& b);
192 const std::string &
str()
const {
199 void deleteNext(
nonneg int count = 1);
204 void deletePrevious(
nonneg int count = 1);
216 const Token *tokAt(
int index)
const;
217 Token *tokAt(
int index);
223 const Token *linkAt(
int index)
const;
224 Token *linkAt(
int index);
230 const std::string &strAt(
int index)
const;
251 template<
size_t count>
253 return simpleMatch(tok, pattern, count-1);
256 static bool simpleMatch(
const Token *tok,
const char pattern[],
size_t pattern_len);
301 static bool Match(
const Token *tok,
const char pattern[],
nonneg int varid = 0);
319 static nonneg int getStrArraySize(
const Token *tok);
332 return mImpl->mValueType;
337 const Token *top =
this;
349 const bool memoizedIsName = (mTokType == eName || mTokType == eType || mTokType == eVariable ||
350 mTokType == eFunction || mTokType == eKeyword || mTokType == eBoolean ||
351 mTokType == eEnumerator);
352 setFlag(fIsName, memoizedIsName);
354 const bool memoizedIsLiteral = (mTokType == eNumber || mTokType == eString || mTokType == eChar ||
355 mTokType == eBoolean || mTokType == eLiteral || mTokType == eEnumerator);
356 setFlag(fIsLiteral, memoizedIsLiteral);
359 return mTokType == eKeyword;
362 return getFlag(fIsName);
365 return mFlags == fIsName && mTokType == eName;
367 bool isUpperCaseName()
const;
369 return getFlag(fIsLiteral);
372 return mTokType == eNumber;
375 return mTokType == eEnumerator;
378 return mTokType == eVariable;
381 return (isConstOp() ||
383 mTokType == eIncDecOp);
386 return (isArithmeticalOp() ||
387 mTokType == eLogicalOp ||
388 mTokType == eComparisonOp ||
392 return isConstOp() ||
393 mTokType == eExtendedOp;
396 return mTokType == eArithmeticalOp;
399 return mTokType == eComparisonOp;
402 return mTokType == eAssignmentOp;
405 return mTokType == eBoolean;
408 return mTokType == eIncDecOp;
411 return astOperand1() !=
nullptr && astOperand2() !=
nullptr;
414 return s == mStr && astOperand1() !=
nullptr && astOperand2() ==
nullptr;
416 bool isUnaryPreOp()
const;
425 return getFlag(fIsUnsigned);
428 setFlag(fIsUnsigned,
sign);
431 return getFlag(fIsSigned);
434 setFlag(fIsSigned,
sign);
438 return getFlag(fIsPointerCompare);
441 setFlag(fIsPointerCompare, b);
444 return getFlag(fIsLong);
447 setFlag(fIsLong, size);
450 return getFlag(fIsStandardType);
453 setFlag(fIsStandardType, b);
456 return !mImpl->mMacroName.empty();
459 return getFlag(fIsCast);
465 return getFlag(fIsAttributeConstructor);
468 setFlag(fIsAttributeConstructor, ac);
471 return getFlag(fIsAttributeDestructor);
474 setFlag(fIsAttributeDestructor, value);
477 return getFlag(fIsAttributeUnused);
480 setFlag(fIsAttributeUnused,
unused);
483 return getFlag(fIsAttributeUsed);
486 setFlag(fIsAttributeUsed,
unused);
489 return getFlag(fIsAttributePure);
492 setFlag(fIsAttributePure, value);
495 return getFlag(fIsAttributeConst);
498 setFlag(fIsAttributeConst, value);
501 return getFlag(fIsAttributeNoreturn);
504 setFlag(fIsAttributeNoreturn, value);
507 return getFlag(fIsAttributeNothrow);
510 setFlag(fIsAttributeNothrow, value);
513 return getFlag(fIsAttributeExport);
516 setFlag(fIsAttributeExport, value);
519 return getFlag(fIsAttributePacked);
522 setFlag(fIsAttributePacked, value);
525 return getFlag(fIsAttributeNodiscard);
528 setFlag(fIsAttributeNodiscard, value);
531 return getFlag(fIsAttributeMaybeUnused);
534 setFlag(fIsAttributeMaybeUnused, value);
537 mImpl->setCppcheckAttribute(type, value);
540 return mImpl->getCppcheckAttribute(type, value);
544 return nullptr != mImpl->mCppcheckAttributes;
547 return getFlag(fIsControlFlowKeyword);
550 return getFlag(fIsOperatorKeyword);
553 setFlag(fIsOperatorKeyword, value);
556 return getFlag(fIsComplex);
559 setFlag(fIsComplex, value);
562 return getFlag(fIsEnumType);
565 setFlag(fIsEnumType, value);
568 return getFlag(fAtAddress);
571 setFlag(fAtAddress, b);
574 return getFlag(fIncompleteVar);
577 setFlag(fIncompleteVar, b);
581 return getFlag(fIsSimplifiedTypedef);
584 setFlag(fIsSimplifiedTypedef, b);
588 return getFlag(fIsIncompleteConstant);
591 setFlag(fIsIncompleteConstant, b);
595 return getFlag(fConstexpr);
598 setFlag(fConstexpr, b);
602 return getFlag(fExternC);
605 setFlag(fExternC, b);
609 return getFlag(fIsSplitVarDeclComma);
612 setFlag(fIsSplitVarDeclComma, b);
616 return getFlag(fIsSplitVarDeclEq);
619 setFlag(fIsSplitVarDeclEq, b);
623 return getFlag(fIsImplicitInt);
626 setFlag(fIsImplicitInt, b);
630 return getFlag(fIsInline);
633 setFlag(fIsInline, b);
637 return getFlag(fIsAtomic);
640 setFlag(fIsAtomic, b);
644 return getFlag(fIsRestrict);
647 setFlag(fIsRestrict, b);
651 return getFlag(fIsRemovedVoidParameter);
654 setFlag(fIsRemovedVoidParameter, b);
658 return getFlag(fIsTemplate);
661 setFlag(fIsTemplate, b);
665 return getFlag(fIsSimplifedScope);
668 setFlag(fIsSimplifedScope, b);
672 return getFlag(fIsFinalType);
675 setFlag(fIsFinalType, b);
679 return getFlag(fIsInitComma);
682 setFlag(fIsInitComma, b);
687 return mImpl->mBits > 0;
693 return mImpl->mTemplateSimplifierPointers;
696 return mImpl->mTemplateSimplifierPointers;
699 if (!mImpl->mTemplateSimplifierPointers)
700 mImpl->mTemplateSimplifierPointers =
new std::set<TemplateSimplifier::TokenAndName*>;
701 mImpl->mTemplateSimplifierPointers->insert(tokenAndName);
729 (mStr.length() > 3));
749 return getFlag(fIsTemplateArg);
752 setFlag(fIsTemplateArg, value);
756 return mImpl->mMacroName;
759 mImpl->mMacroName = std::move(name);
762 template<
size_t count>
764 return findsimplematch(startTok, pattern, count-1);
766 static const Token *findsimplematch(
const Token *
const startTok,
const char pattern[],
size_t pattern_len);
768 template<
size_t count>
770 return findsimplematch(startTok, pattern, count-1, end);
772 static const Token *findsimplematch(
const Token *
const startTok,
const char pattern[],
size_t pattern_len,
const Token *
const end);
774 static const Token *findmatch(
const Token *
const startTok,
const char pattern[],
const nonneg int varId = 0);
775 static const Token *findmatch(
const Token *
const startTok,
const char pattern[],
const Token *
const end,
const nonneg int varId = 0);
777 template<
size_t count>
779 return findsimplematch(startTok, pattern, count-1);
781 static Token *findsimplematch(
Token *
const startTok,
const char pattern[],
size_t pattern_len);
782 template<
size_t count>
784 return findsimplematch(startTok, pattern, count-1, end);
786 static Token *findsimplematch(
Token *
const startTok,
const char pattern[],
size_t pattern_len,
const Token *
const end);
788 static Token *findmatch(
Token *
const startTok,
const char pattern[],
const nonneg int varId = 0);
789 static Token *findmatch(
Token *
const startTok,
const char pattern[],
const Token *
const end,
const nonneg int varId = 0);
806 static int multiCompare(
const Token *tok,
const char *haystack,
nonneg int varid);
810 return mImpl->mFileIndex;
813 mImpl->mFileIndex = indexOfFile;
817 return mImpl->mLineNumber;
820 mImpl->mLineNumber = lineNumber;
824 return mImpl->mColumn;
845 static void eraseTokens(
Token *begin,
const Token *end);
855 Token* insertToken(
const std::string& tokenStr,
const std::string& originalNameStr =
emptyString,
const std::string& macroNameStr =
emptyString,
bool prepend =
false);
859 return insertToken(tokenStr, originalNameStr, macroNameStr,
true);
871 return mImpl->mVarId;
877 isStandardType(
false);
879 update_property_info();
885 return mImpl->mExprId;
886 return mImpl->mVarId;
894 assert(mImpl->mExprId > 0);
895 mImpl->mExprId |= 1 << efIsUnique;
900 return (mImpl->mExprId & (1 << efIsUnique)) != 0;
909 void printOut(
const char *title =
nullptr)
const;
919 void printOut(
const char *title,
const std::vector<std::string> &fileNames)
const;
924 void printLines(
int lines=5)
const;
939 bool attributes =
false;
941 bool linenumbers =
false;
942 bool linebreaks =
false;
947 options.
macro =
true;
950 options.
files =
true;
956 options.
varid =
true;
967 options.
varid =
true;
973 std::string stringify(
const stringifyOptions& options)
const;
981 std::string stringify(
bool varid,
bool attributes,
bool macro)
const;
983 std::string stringifyList(
const stringifyOptions& options,
const std::vector<std::string>* fileNames =
nullptr,
const Token* end =
nullptr)
const;
984 std::string stringifyList(
const Token* end,
bool attributes =
true)
const;
985 std::string stringifyList(
bool varid =
false)
const;
998 std::string stringifyList(
bool varid,
bool attributes,
bool linenumbers,
bool linebreaks,
bool files,
const std::vector<std::string>* fileNames =
nullptr,
const Token* end =
nullptr)
const;
1016 mLink = linkToToken;
1017 if (mStr ==
"<" || mStr ==
">")
1018 update_property_info();
1050 return mImpl->mScope;
1063 return mTokType == eFunction || mTokType == eLambda ? mImpl->mFunction :
nullptr;
1071 mImpl->mVariable = v;
1072 if (v || mImpl->mVarId)
1074 else if (mTokType == eVariable)
1082 return mTokType == eVariable ? mImpl->mVariable :
nullptr;
1089 void type(const ::Type *t);
1095 return mTokType == eType ? mImpl->mType :
nullptr;
1098 static const ::Type* typeOf(
const Token* tok,
const Token** typeTok =
nullptr);
1104 static std::pair<const Token*, const Token*> typeDecl(
const Token* tok,
bool pointedToType =
false);
1106 static std::string typeStr(
const Token* tok);
1112 return mTokType == eEnumerator ? mImpl->mEnumerator :
nullptr;
1120 mImpl->mEnumerator = e;
1122 tokType(eEnumerator);
1123 else if (mTokType == eEnumerator)
1130 static void createMutualLinks(
Token *begin,
Token *end);
1138 std::string strValue()
const;
1151 return mImpl->mProgressValue;
1155 static void assignProgressValues(
Token *tok);
1162 const Token* nextArgument()
const;
1163 Token *nextArgument();
1170 const Token* nextArgumentBeforeCreateLinks2()
const;
1177 const Token* nextTemplateArgument()
const;
1184 const Token* findClosingBracket()
const;
1185 Token* findClosingBracket();
1187 const Token* findOpeningBracket()
const;
1188 Token* findOpeningBracket();
1194 return mImpl->mOriginalName ? *mImpl->mOriginalName :
emptyString;
1197 const std::list<ValueFlow::Value>&
values()
const {
1204 template<
typename T>
1206 if (!mImpl->mOriginalName)
1207 mImpl->mOriginalName =
new std::string(name);
1209 *mImpl->mOriginalName = name;
1212 bool hasKnownIntValue()
const;
1213 bool hasKnownValue()
const;
1215 bool hasKnownSymbolicValue(
const Token* tok)
const;
1219 return mImpl->mValues->front().intvalue;
1236 const Token *getValueTokenMaxStrLength()
const;
1244 mImpl->mValues->remove_if(std::move(pred));
1248 return mImpl->mIndex;
1251 void assignIndexes();
1259 mPrevious = previousToken;
1263 void takeData(
Token *fromToken);
1270 static bool firstWordEquals(
const char *str,
const char *word);
1277 static const char *chrInFirstWord(
const char *str,
char c);
1286 fIsUnsigned = (1ULL << 0),
1287 fIsSigned = (1ULL << 1),
1288 fIsPointerCompare = (1ULL << 2),
1289 fIsLong = (1ULL << 3),
1290 fIsStandardType = (1ULL << 4),
1292 fIsCast = (1ULL << 6),
1293 fIsAttributeConstructor = (1ULL << 7),
1294 fIsAttributeDestructor = (1ULL << 8),
1295 fIsAttributeUnused = (1ULL << 9),
1296 fIsAttributePure = (1ULL << 10),
1297 fIsAttributeConst = (1ULL << 11),
1298 fIsAttributeNoreturn = (1ULL << 12),
1299 fIsAttributeNothrow = (1ULL << 13),
1300 fIsAttributeUsed = (1ULL << 14),
1301 fIsAttributePacked = (1ULL << 15),
1302 fIsAttributeExport = (1ULL << 16),
1303 fIsAttributeMaybeUnused = (1ULL << 17),
1304 fIsAttributeNodiscard = (1ULL << 18),
1305 fIsControlFlowKeyword = (1ULL << 19),
1306 fIsOperatorKeyword = (1ULL << 20),
1307 fIsComplex = (1ULL << 21),
1308 fIsEnumType = (1ULL << 22),
1309 fIsName = (1ULL << 23),
1310 fIsLiteral = (1ULL << 24),
1311 fIsTemplateArg = (1ULL << 25),
1312 fAtAddress = (1ULL << 26),
1313 fIncompleteVar = (1ULL << 27),
1314 fConstexpr = (1ULL << 28),
1315 fExternC = (1ULL << 29),
1316 fIsSplitVarDeclComma = (1ULL << 30),
1317 fIsSplitVarDeclEq = (1ULL << 31),
1318 fIsImplicitInt = (1ULL << 32),
1319 fIsInline = (1ULL << 33),
1320 fIsTemplate = (1ULL << 34),
1321 fIsSimplifedScope = (1ULL << 35),
1322 fIsRemovedVoidParameter = (1ULL << 36),
1323 fIsIncompleteConstant = (1ULL << 37),
1324 fIsRestrict = (1ULL << 38),
1325 fIsAtomic = (1ULL << 39),
1326 fIsSimplifiedTypedef = (1ULL << 40),
1327 fIsFinalType = (1ULL << 41),
1328 fIsInitComma = (1ULL << 42),
1333 efIsUnique = efMaxSize - 2,
1348 return ((mFlags & flag_) != 0);
1357 mFlags = state_ ? mFlags | flag_ : mFlags & ~flag_;
1362 void update_property_info();
1365 void update_property_isStandardType();
1368 void update_property_char_string_literal();
1371 void astStringVerboseRecursive(std::string& ret,
const nonneg int indent1 = 0,
const nonneg int indent2 = 0)
const;
1374 void astOperand1(
Token *tok);
1375 void astOperand2(
Token *tok);
1376 void astParent(
Token* tok);
1379 return mImpl->mAstOperand1;
1382 return mImpl->mAstOperand1;
1385 return mImpl->mAstOperand2;
1388 return mImpl->mAstOperand2;
1391 return mImpl->mAstParent;
1394 return mImpl->mAstParent;
1399 if (
this == astParent()->astOperand1())
1401 if (
this == astParent()->astOperand2())
1402 return astParent()->astOperand1();
1409 if (
this == astParent()->astOperand1())
1411 if (
this == astParent()->astOperand2())
1412 return astParent()->astOperand1();
1424 const Token *ret =
this;
1430 std::pair<const Token *, const Token *> findExpressionStartEndTokens()
const;
1439 bool isCalculation()
const;
1442 delete mImpl->mValues;
1443 mImpl->mValues =
nullptr;
1448 if (mImpl->mAstOperand1)
1449 ret = mImpl->mAstOperand1->astString(sep);
1450 if (mImpl->mAstOperand2)
1451 ret += mImpl->mAstOperand2->astString(sep);
1452 return ret + sep + mStr;
1455 std::string astStringVerbose()
const;
1457 std::string astStringZ3()
const;
1459 std::string expressionString()
const;
1461 void printAst(
bool verbose,
bool xml,
const std::vector<std::string> &fileNames, std::ostream &out)
const;
1463 void printValueFlow(
bool xml, std::ostream &out)
const;
1465 void scopeInfo(std::shared_ptr<ScopeInfo2> newScopeInfo);
1466 std::shared_ptr<ScopeInfo2> scopeInfo()
const;
1472 return mImpl->mCpp11init;
1476 return mImpl->mDebug;
static int sign(const T v)
This is just a container for general settings so that we don't need to pass individual values to func...
Token and its full scopename.
The token list that the TokenList generates is a linked-list of this class.
bool isRemovedVoidParameter() const
Token(const Token &)=delete
void isAttributeNodiscard(const bool value)
std::string astString(const char *sep="") const
void isIncompleteConstant(bool b)
static Token * findsimplematch(Token *const startTok, const char(&pattern)[count], const Token *const end)
void next(Token *nextToken)
static bool Match(const Token *tok, const char pattern[], nonneg int varid=0)
Match given token (or list of tokens) to a pattern list.
void isComplex(const bool value)
bool isSimplifiedScope() const
void exprId(nonneg int id)
void isAttributeUsed(const bool unused)
nonneg int exprId() const
void isEnumType(const bool value)
void isSigned(const bool sign)
bool isEnumerator() const
unsigned char bits() const
void setMacroName(std::string name)
const std::string & originalName() const
void fileIndex(nonneg int indexOfFile)
const Token * previous() const
void setCppcheckAttribute(TokenImpl::CppcheckAttributes::Type type, MathLib::bigint value)
bool isAttributeUsed() const
TokenImpl::Cpp11init isCpp11init() const
void isAttributePure(const bool value)
MathLib::bigint getKnownIntValue() const
void removeValues(std::function< bool(const ValueFlow::Value &)> pred)
bool isSimplifiedTypedef() const
const Token * astSibling() const
bool isExpandedMacro() const
void varId(nonneg int id)
static Token * findsimplematch(Token *const startTok, const char(&pattern)[count])
bool isTemplateArg() const
Is current token a template argument?
void isAttributeUnused(bool unused)
void previous(Token *previousToken)
const Token * astOperand1() const
void setTokenDebug(TokenDebug td)
void isAttributeNothrow(const bool value)
void isSimplifiedTypedef(bool b)
void templateSimplifierPointer(TemplateSimplifier::TokenAndName *tokenAndName)
bool isArithmeticalOp() const
const Token * link() const
Return token where this token links to.
void linenr(nonneg int lineNumber)
void isAttributeExport(const bool value)
bool isIncompleteVar() const
const Token * astParent() const
static const Token * findsimplematch(const Token *const startTok, const char(&pattern)[count], const Token *const end)
void column(nonneg int c)
bool isExtendedOp() const
bool isPointerCompare() const
void isAttributeDestructor(const bool value)
void isSimplifiedScope(bool b)
bool isAttributeDestructor() const
void isImplicitInt(bool b)
nonneg int progressValue() const
Get progressValue (0 - 100)
const Scope * scope() const
bool isControlFlowKeyword() const
void isPointerCompare(const bool b)
void setBits(const unsigned char b)
const Token * astOperand2() const
bool isUniqueExprId() const
bool isImplicitInt() const
const ValueType * valueType() const
bool isAttributeUnused() const
void enumerator(const Enumerator *e)
Associate this token with given enumerator.
const Enumerator * enumerator() const
const Token * astTop() const
TokensFrontBack & mTokensFrontBack
bool isCMultiChar() const
void flags(const uint64_t flags_)
void isAttributeConstructor(const bool ac)
void isAttributeNoreturn(const bool value)
std::set< TemplateSimplifier::TokenAndName * > * templateSimplifierPointers()
const std::string & str() const
void setFlag(uint64_t flag_, bool state_)
Set specified flag state.
bool isSplittedVarDeclComma() const
bool isUnaryOp(const std::string &s) const
const ValueType * argumentType() const
bool isAttributeNodiscard() const
bool isAttributeExport() const
bool isOperatorKeyword() const
void isIncompleteVar(bool b)
bool isIncompleteConstant() const
const ::Type * type() const
bool isAttributeConstructor() const
void setRemovedVoidParameter(bool b)
void originalName(T &&name)
Sets the original name.
const std::set< TemplateSimplifier::TokenAndName * > * templateSimplifierPointers() const
Token & operator=(const Token &)=delete
TokenDebug getTokenDebug() const
void setCpp11init(bool cpp11init) const
static const Token * findsimplematch(const Token *const startTok, const char(&pattern)[count])
void isAttributeConst(bool value)
Token * insertTokenBefore(const std::string &tokenStr, const std::string &originalNameStr=emptyString, const std::string ¯oNameStr=emptyString)
bool hasCppcheckAttributes() const
const Variable * variable() const
bool getFlag(uint64_t flag_) const
Get specified flag state.
Token::Type tokType() const
void astOperand2(Token *tok)
void isOperatorKeyword(const bool value)
void scope(const Scope *s)
Associate this token with given scope.
void link(Token *linkToToken)
Create link to given token.
void tokType(Token::Type t)
void isAttributeMaybeUnused(const bool value)
void isAttributePacked(const bool value)
void isSplittedVarDeclEq(bool b)
void isUnsigned(const bool sign)
void isTemplateArg(const bool value)
bool isAssignmentOp() const
bool isSplittedVarDeclEq() const
const Token * next() const
void isStandardType(const bool b)
nonneg int linenr() const
bool isStandardType() const
void variable(const Variable *v)
Associate this token with given variable.
bool isAttributeMaybeUnused() const
bool isComparisonOp() const
const std::list< ValueFlow::Value > & values() const
bool isAttributeNoreturn() const
bool isAttributeConst() const
static bool simpleMatch(const Token *tok, const char(&pattern)[count])
Match given token (or list of tokens) to a pattern list.
nonneg int fileIndex() const
void isSplittedVarDeclComma(bool b)
bool isAttributePacked() const
bool isAttributeNothrow() const
std::string getMacroName() const
nonneg int column() const
bool isAttributePure() const
bool getCppcheckAttribute(TokenImpl::CppcheckAttributes::Type type, MathLib::bigint &value) const
void astParent(Token *tok)
Information about a class type.
Information about a member variable.
static const std::string emptyString
static void replace(std::string &source, const std::unordered_map< std::string, std::string > &substitutionMap)
Token * findTypeEnd(Token *tok)
Token * findLambdaEndScope(Token *tok)
std::vector< MathLib::bigint > getMinValue(const ValuePtr< InferModel > &model, const std::list< ValueFlow::Value > &values)
std::vector< MathLib::bigint > getMaxValue(const ValuePtr< InferModel > &model, const std::list< ValueFlow::Value > &values)
const Token *const bodyEnd
ScopeInfo2(std::string name_, const Token *bodyEnd_, std::set< std::string > usingNamespaces_=std::set< std::string >())
std::set< std::string > usingNamespaces
enum TokenImpl::CppcheckAttributes::Type type
CppcheckAttributes * next
std::list< ValueFlow::Value > * mValues
const Function * mFunction
const Enumerator * mEnumerator
std::string * mOriginalName
static const std::list< ValueFlow::Value > mEmptyValueList
unsigned char mBits
Bitfield bit count.
nonneg int mProgressValue
A value from 0-100 that provides a rough idea about where in the token list this token is located.
const Variable * mVariable
std::set< TemplateSimplifier::TokenAndName * > * mTemplateSimplifierPointers
CppcheckAttributes * mCppcheckAttributes
std::shared_ptr< ScopeInfo2 > mScopeInfo
void setCppcheckAttribute(CppcheckAttributes::Type type, MathLib::bigint value)
nonneg int mIndex
Token index.
enum TokenImpl::Cpp11init mCpp11init
bool getCppcheckAttribute(CppcheckAttributes::Type type, MathLib::bigint &value) const
static stringifyOptions forDebugExprId()
static stringifyOptions forDebugVarId()
static stringifyOptions forPrintOut()
static stringifyOptions forDebug()
This struct stores pointers to the front and back tokens of the list this token is in.
static UNUSED void unused()
static bool isPrefixStringCharLiteral(const std::string &str, char q, const std::string &p)