From 1e6dfe458079620a7192381dce9505e94a83518a Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Tue, 23 Feb 2016 08:18:13 +0200 Subject: cid#1353438 Logically dead code Change-Id: Ib444a1941e2bec03394c4e8eb7a5a34adbe3f4f6 --- idl/source/prj/parser.cxx | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) (limited to 'idl/source') diff --git a/idl/source/prj/parser.cxx b/idl/source/prj/parser.cxx index b8899313c586..f9e2f0f8c53e 100644 --- a/idl/source/prj/parser.cxx +++ b/idl/source/prj/parser.cxx @@ -323,7 +323,8 @@ void SvIdlParser::ReadInterfaceOrShellEntry(SvMetaClass& rClass) else { xAttr = new SvMetaAttribute( pType ); - bOk = ReadInterfaceOrShellMethodOrAttribute(*xAttr); + ReadInterfaceOrShellMethodOrAttribute(*xAttr); + bOk = true; } if( bOk ) bOk = xAttr->Test( rInStm ); @@ -387,10 +388,8 @@ bool SvIdlParser::ReadInterfaceOrShellSlot(SvMetaSlot& rSlot) return bOk; } -bool SvIdlParser::ReadInterfaceOrShellMethodOrAttribute( SvMetaAttribute& rAttr ) +void SvIdlParser::ReadInterfaceOrShellMethodOrAttribute( SvMetaAttribute& rAttr ) { - sal_uInt32 nTokPos = rInStm.Tell(); - bool bOk = false; rAttr.SetName( ReadIdentifier() ); rAttr.aSlotId.setString( ReadIdentifier() ); sal_uLong n; @@ -398,7 +397,6 @@ bool SvIdlParser::ReadInterfaceOrShellMethodOrAttribute( SvMetaAttribute& rAttr throw SvParseException( rInStm, "no value for identifier <" + rAttr.aSlotId.getString() + "> " ); rAttr.aSlotId.SetValue(n); - bOk = true; if( ReadIf( '(' ) ) { // read method arguments @@ -420,14 +418,10 @@ bool SvIdlParser::ReadInterfaceOrShellMethodOrAttribute( SvMetaAttribute& rAttr Read( ')' ); rAttr.aType->SetType( MetaTypeType::Method ); } - if( bOk && ReadIf( '[' ) ) + if( ReadIf( '[' ) ) { Read( ']' ); } - - if( !bOk ) - rInStm.Seek( nTokPos ); - return bOk; } SvMetaClass * SvIdlParser::ReadKnownClass() -- cgit