Started by Juergen Kuehlwein, April 09, 2018, 11:39:00 PM
0 Members and 1 Guest are viewing this topic.
QuoteEasiest way to see the difference is do a new clone & checkout, forcing the autocrlf setting for comparison.
QuoteThe only files that must be LF are./manual/cache/*.wakka (raw data files from wiki)./tests/file/big-list-eol-lf.txt (a specific test that needs LF on all targets)
# Auto detect text files and perform LF normalization* text=auto# BASIC source files (need cr/lf line endings)*.bas text*.bi text*.inc text*.h text*.bat text*.txt text*.jkp text*.rc text*.gif binary*.jpg binary*.png binary./manual/cache/*.wakka eol=lf ./tests/file/big-list-eol-lf.txt eol=lf
QuoteI really want to get the 1.06 release out first
TYPE DWSTR m_pBuffer AS UBYTE PTR 'pointer to the buffer (in first place -> make strptr possible) Private: m_Capacity AS Ulong 'the total size of the buffer m_GrowSize AS LONG = 260 * SizeOf(WSTRING) 'how much to grow the buffer by when required Public: m_BufferLen AS ulong 'length in bytes of the current string in the buffer
DECLARE OPERATOR CAST () BYREF AS WSTRING DECLARE OPERATOR CAST () AS ANY PTR
type T extends wstring '' or zstring '' ...end type
type UWSTRING_FIXED extends wstring private: _data as wstring * 256 public: declare constructor() declare constructor( byval rhs as const wstring const ptr ) declare constructor( byval rhs as const zstring const ptr ) declare operator cast() byref as wstring declare const function length() as integerend typeconstructor UWSTRING_FIXED() _data = ""end constructorconstructor UWSTRING_FIXED( byval s as const wstring const ptr ) _data = *send constructorconstructor UWSTRING_FIXED( byval s as const zstring const ptr ) _data = wstr( *s )end constructoroperator UWSTRING_FIXED.Cast() byref as wstring operator = *cast(wstring ptr, @_data) end operatorconst function UWSTRING_FIXED.length() as integer function = len( _data )end functionoperator Len( byref s as const UWSTRING_FIXED ) as integer return s.Length()end operator
dim w as wstring * 50 = " "dim r as wstring * 50 = trim(w)
QuoteA requirement that the m_pBuffer element be first element should not be required. Instead, fbc should be calling an operator overload to get the data's address if the user has defined one. Or maybe it needs to be a requirement of the UDT that the user writes.
... chars = fb_wstr_Len( src ); if( chars <= 0 ) return NULL; if( wcscmp(src, L" ") == 0) //added return NULL; //added ...
if( wcscmp(src, L" ") == 0) //added return NULL; //added
Page created in 0.253 seconds with 21 queries.