diff options
author | Caolán McNamara <caolanm@redhat.com> | 2011-09-18 22:35:32 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2011-09-19 09:59:23 +0100 |
commit | 7a142d8932990b253e51be29b1f0b861c9111d9f (patch) | |
tree | d6cc29b7ec14c8e9da7ff7cf06c60f63bc9624db /basic | |
parent | ByteString->rtl::OStringBuffer (diff) | |
download | core-7a142d8932990b253e51be29b1f0b861c9111d9f.tar.gz core-7a142d8932990b253e51be29b1f0b861c9111d9f.zip |
drop intermediate ByteString
Diffstat (limited to 'basic')
-rw-r--r-- | basic/source/runtime/methods.cxx | 11 | ||||
-rw-r--r-- | basic/source/runtime/step1.cxx | 2 |
2 files changed, 6 insertions, 7 deletions
diff --git a/basic/source/runtime/methods.cxx b/basic/source/runtime/methods.cxx index 2f110304d5b5..2123d940fd34 100644 --- a/basic/source/runtime/methods.cxx +++ b/basic/source/runtime/methods.cxx @@ -369,17 +369,16 @@ void implChr( SbxArray& rPar, bool bChrW ) { SbxVariableRef pArg = rPar.Get( 1 ); - String aStr; + rtl::OUString aStr; if( !bChrW && SbiRuntime::isVBAEnabled() ) { - sal_Char c = (sal_Char)pArg->GetByte(); - ByteString s( c ); - aStr = String( s, gsl_getSystemTextEncoding() ); + sal_Char c = static_cast<sal_Char>(pArg->GetByte()); + aStr = rtl::OUString(&c, 1, gsl_getSystemTextEncoding()); } else { - sal_Unicode aCh = (sal_Unicode)pArg->GetUShort(); - aStr = String( aCh ); + sal_Unicode aCh = static_cast<sal_Unicode>(pArg->GetUShort()); + aStr = rtl::OUString(aCh); } rPar.Get(0)->PutString( aStr ); } diff --git a/basic/source/runtime/step1.cxx b/basic/source/runtime/step1.cxx index 7dbf23e2d319..9fa4e9c4927f 100644 --- a/basic/source/runtime/step1.cxx +++ b/basic/source/runtime/step1.cxx @@ -428,7 +428,7 @@ void SbiRuntime::StepCLOSE( sal_uInt32 nOp1 ) void SbiRuntime::StepPRCHAR( sal_uInt32 nOp1 ) { - ByteString s( (char) nOp1 ); + rtl::OString s(static_cast<sal_Char>(nOp1)); pIosys->Write( s ); Error( pIosys->GetError() ); } |