Le 13/07/2012 23:17, Lubos Lunak a écrit :
according to my understanding,
OUString::compareToAscii(RTL_CONSTASCII_STRINGPARAM("A string")) gives
  compareAsciiL - the L means it gets the string length from the macro
I was speaking about compareToAscii, without the L. compareAsciiL does 
not seem to exist anyway.
     sal_Int32 compareToAscii( const sal_Char * asciiStr, sal_Int32 
maxLength ) const SAL_THROW(())
OUString str_1("abc");
str_1.compareToAscii("a")                             --> should give false
str_1.compareToAscii(RTL_CONSTASCII_STRINGPARAM("a")) --> should give 
true because only the first char of the 2 strings will be compared
In fact I made the same mistake as you. RTL_CONSTASCII_STRINGPARAM made 
me think about the length of the literal but in this case, it also has a 
real effect on the result (unless I'm wrong :))
Context
   
 
  Privacy Policy |
  
Impressum (Legal Info) |
  
Copyright information: Unless otherwise specified, all text and images
  on this website are licensed under the
  
Creative Commons Attribution-Share Alike 3.0 License.
  This does not include the source code of LibreOffice, which is
  licensed under the Mozilla Public License (
MPLv2).
  "LibreOffice" and "The Document Foundation" are
  registered trademarks of their corresponding registered owners or are
  in actual use as trademarks in one or more countries. Their respective
  logos and icons are also subject to international copyright laws. Use
  thereof is explained in our 
trademark policy.