diff options
author | Noel Grandin <noel@peralex.com> | 2016-02-23 08:43:39 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2016-02-23 10:07:10 +0200 |
commit | 799eab3b3499be5846e13e6360cc01741a241f89 (patch) | |
tree | b08e00018f5bab230b6887175b721d4b60bf8a0e /idl/source/prj | |
parent | 1e6dfe458079620a7192381dce9505e94a83518a (diff) |
methods in .SDI files don't use attributes
so simplify the parser and drop the square brackets
Change-Id: I3bab5f5b14e57d0cd1ed1a383fe21968f97b243a
Diffstat (limited to 'idl/source/prj')
-rw-r--r-- | idl/source/prj/parser.cxx | 36 |
1 files changed, 15 insertions, 21 deletions
diff --git a/idl/source/prj/parser.cxx b/idl/source/prj/parser.cxx index f9e2f0f8c53e..dc3340a214b8 100644 --- a/idl/source/prj/parser.cxx +++ b/idl/source/prj/parser.cxx @@ -397,31 +397,25 @@ void SvIdlParser::ReadInterfaceOrShellMethodOrAttribute( SvMetaAttribute& rAttr throw SvParseException( rInStm, "no value for identifier <" + rAttr.aSlotId.getString() + "> " ); rAttr.aSlotId.SetValue(n); - if( ReadIf( '(' ) ) + Read( '(' ); + // read method arguments + tools::SvRef<SvMetaType> xT(new SvMetaType() ); + xT->SetRef(rAttr.GetType() ); + rAttr.aType = xT; + sal_uInt32 nBeginPos = 0; // can not happen with Tell + while( nBeginPos != rInStm.Tell() ) { - // read method arguments - tools::SvRef<SvMetaType> xT(new SvMetaType() ); - xT->SetRef(rAttr.GetType() ); - rAttr.aType = xT; - sal_uInt32 nBeginPos = 0; // can not happen with Tell - while( nBeginPos != rInStm.Tell() ) + nBeginPos = rInStm.Tell(); + tools::SvRef<SvMetaAttribute> xAttr( new SvMetaAttribute() ); + if( xAttr->ReadSvIdl( rBase, rInStm ) ) { - nBeginPos = rInStm.Tell(); - tools::SvRef<SvMetaAttribute> xAttr( new SvMetaAttribute() ); - if( xAttr->ReadSvIdl( rBase, rInStm ) ) - { - if( xAttr->Test( rInStm ) ) - rAttr.aType->GetAttrList().push_back( xAttr ); - } - ReadIfDelimiter(); + if( xAttr->Test( rInStm ) ) + rAttr.aType->GetAttrList().push_back( xAttr ); } - Read( ')' ); - rAttr.aType->SetType( MetaTypeType::Method ); - } - if( ReadIf( '[' ) ) - { - Read( ']' ); + ReadIfDelimiter(); } + Read( ')' ); + rAttr.aType->SetType( MetaTypeType::Method ); } SvMetaClass * SvIdlParser::ReadKnownClass() |