Skip to content
Snippets Groups Projects
Commit 384c3cbe authored by Tomáš Pecka's avatar Tomáš Pecka
Browse files

RTE: Fix parsing of Alphabet Symbol

parent 8b8e118e
No related branches found
No related tags found
1 merge request!30RTE: Fix parsing of Alphabet Symbol
Pipeline #
......@@ -10,13 +10,15 @@
 
#include <set>
#include <deque>
#include "../RTEFeatures.h"
#include <sax/Token.h>
#include <alphabet/ranked_symbol.hpp>
#include <core/xmlApi.hpp>
#include <exception/CommonException.h>
 
#include "../RTEFeatures.h"
#include "../formal/FormalRTEElements.h"
#include <core/xmlApi.hpp>
 
namespace rte {
 
......@@ -153,6 +155,9 @@ std::rvalue_ref < FormalRTESymbolAlphabet < SymbolType, RankType > > RTEFromXMLP
while ( sax::FromXMLParserHelper::isTokenType ( input, sax::Token::TokenType::START_ELEMENT ) )
elements.push_back ( parseFormalRTESymbol < SymbolType, RankType > ( input ) );
 
if ( elements.size() != ( size_t ) symbol.getRank( ) )
throw exception::CommonException ( "Parsed symbol's rank and number of children differ." );
for ( std::rvalue_ref < FormalRTESymbol < SymbolType, RankType > > & element : elements )
ret->appendElement ( element );
 
......
  • Owner

    Takhle nějak by to být mělo. RankType by měl být takhle přetypovatelný.

  • Author Owner

    V tom případě prosím o merge až se to dokompiluje.

0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment