8#if !defined(ALIB_C20_MODULES) || ((ALIB_C20_MODULES != 0) && (ALIB_C20_MODULES != 1))
9# error "Configuration MACRO ALIB_C20_MODULES has to be given to the compiler as either 0 or 1"
19 module ALib.Expressions;
20 import ALib.Expressions.Impl;
21 import ALib.Characters.Functions;
24 import ALib.Camp.Base;
45 String256 escapedFS; escapedFS.DbgDisableBufferReplacementWarning();
51 while(parsePos < escapedFS.Length() ) {
55 if( ( parsePos= escapedFS.IndexOf( A_CHAR(
'{'), parsePos ) ) < 0
56 || parsePos == escapedFS.Length() - 1 )
58 formatStringStripped << escapedFS.Substring( nonExprPortionStart );
64 if( escapedFS[parsePos] ==
A_CHAR(
'{') ) {
70 formatStringStripped << escapedFS.Substring( nonExprPortionStart, parsePos - nonExprPortionStart );
75 while( endPos < escapedFS.Length() -1
76 && escapedFS[endPos] != separatorChar
77 && escapedFS[endPos] !=
A_CHAR(
'}') )
81 String expressionString= escapedFS.Substring( parsePos, endPos - parsePos );
82 nonExprPortionStart= endPos;
83 if( escapedFS[endPos] == separatorChar )
84 ++nonExprPortionStart;
94 formatSubstrings.push_back(formatStringStripped.Length());
106 for(
size_t expressionNo= 0; expressionNo <
expressions.size() ; ++expressionNo ) {
112 stdFormatter->Format( target, formatString, exprResult );
#define ALIB_CALLER_NULLED
Exception & Add(const lang::CallerInfo &ci, TEnum type, TArgs &&... args)
Utility types of camp ALib Expressions.
containers::SharedPtr< format::Formatter > SPFormatter
strings::util::StringEscaperStandard StringEscaperStandard
Type alias in namespace alib.
strings::TEscape< character > Escape
Type alias in namespace alib.
constexpr const String EMPTY_STRING
An empty string of the default character type.
lang::integer integer
Type alias in namespace alib.
boxing::Box Box
Type alias in namespace alib.
strings::TString< character > String
Type alias in namespace alib.
exceptions::Exception Exception
Type alias in namespace alib.
LocalString< 256 > String256
Type alias name for #"TLocalString;TLocalString<character,256>".
strings::TAString< character, lang::HeapAllocator > AString
Type alias in namespace alib.
characters::character character
Type alias in namespace alib.