IBIS: add stub for Model Spec; support empty strings in line with keywords.
(cherry picked from commit 08e6e0258f
)
This commit is contained in:
parent
6331a0ab7a
commit
6245bbff50
|
@ -1135,8 +1135,8 @@ bool IbisParser::readString( std::string& aDest )
|
||||||
|
|
||||||
if( len < 1 )
|
if( len < 1 )
|
||||||
{
|
{
|
||||||
Report( _( "Unable to read string, input is empty." ), RPT_SEVERITY_ERROR );
|
// The data is likely on the next line. Skip.
|
||||||
return false;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
char c = aDest[len - 1];
|
char c = aDest[len - 1];
|
||||||
|
@ -1436,6 +1436,20 @@ bool IbisParser::readRamp()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
bool IbisParser::readModelSpec()
|
||||||
|
{
|
||||||
|
bool status = true;
|
||||||
|
|
||||||
|
m_continue = IBIS_PARSER_CONTINUE::MODEL_SPEC;
|
||||||
|
|
||||||
|
// TODO
|
||||||
|
// readTypMinMaxValueSubparam( std::string( "Vmeas" ), m_currentModel->... )
|
||||||
|
// ...
|
||||||
|
|
||||||
|
return status;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
bool IbisParser::parseModel( std::string& aKeyword )
|
bool IbisParser::parseModel( std::string& aKeyword )
|
||||||
{
|
{
|
||||||
bool status = false;
|
bool status = false;
|
||||||
|
@ -1458,6 +1472,8 @@ bool IbisParser::parseModel( std::string& aKeyword )
|
||||||
status = readWaveform( nullptr, IBIS_WAVEFORM_TYPE::FALLING );
|
status = readWaveform( nullptr, IBIS_WAVEFORM_TYPE::FALLING );
|
||||||
else if( compareIbisWord( aKeyword.c_str(), "Ramp" ) )
|
else if( compareIbisWord( aKeyword.c_str(), "Ramp" ) )
|
||||||
status = readRamp();
|
status = readRamp();
|
||||||
|
else if( compareIbisWord( aKeyword.c_str(), "Model_Spec" ) )
|
||||||
|
status = readModelSpec();
|
||||||
else if( compareIbisWord( aKeyword.c_str(), "Pullup_Reference" ) )
|
else if( compareIbisWord( aKeyword.c_str(), "Pullup_Reference" ) )
|
||||||
status = readTypMinMaxValue( m_currentModel->m_pullupReference );
|
status = readTypMinMaxValue( m_currentModel->m_pullupReference );
|
||||||
else if( compareIbisWord( aKeyword.c_str(), "Pulldown_Reference" ) )
|
else if( compareIbisWord( aKeyword.c_str(), "Pulldown_Reference" ) )
|
||||||
|
@ -2577,6 +2593,7 @@ bool IbisParser::onNewLine()
|
||||||
status &= readWaveform( m_currentWaveform, m_currentWaveform->m_type );
|
status &= readWaveform( m_currentWaveform, m_currentWaveform->m_type );
|
||||||
break;
|
break;
|
||||||
case IBIS_PARSER_CONTINUE::RAMP: status &= readRamp(); break;
|
case IBIS_PARSER_CONTINUE::RAMP: status &= readRamp(); break;
|
||||||
|
case IBIS_PARSER_CONTINUE::MODEL_SPEC: status &= readModelSpec(); break;
|
||||||
case IBIS_PARSER_CONTINUE::PACKAGEMODEL_PINS: status &= readPackageModelPins(); break;
|
case IBIS_PARSER_CONTINUE::PACKAGEMODEL_PINS: status &= readPackageModelPins(); break;
|
||||||
case IBIS_PARSER_CONTINUE::MATRIX: status &= readMatrix( m_currentMatrix ); break;
|
case IBIS_PARSER_CONTINUE::MATRIX: status &= readMatrix( m_currentMatrix ); break;
|
||||||
case IBIS_PARSER_CONTINUE::NONE:
|
case IBIS_PARSER_CONTINUE::NONE:
|
||||||
|
|
|
@ -632,6 +632,7 @@ enum class IBIS_PARSER_CONTINUE
|
||||||
MATRIX,
|
MATRIX,
|
||||||
MODELSELECTOR,
|
MODELSELECTOR,
|
||||||
MODEL,
|
MODEL,
|
||||||
|
MODEL_SPEC,
|
||||||
IV_TABLE,
|
IV_TABLE,
|
||||||
VT_TABLE,
|
VT_TABLE,
|
||||||
RAMP,
|
RAMP,
|
||||||
|
@ -772,6 +773,7 @@ private:
|
||||||
bool readMatrixSparse( std::string, IBIS_MATRIX_SPARSE& aDest );
|
bool readMatrixSparse( std::string, IBIS_MATRIX_SPARSE& aDest );
|
||||||
bool readRampdvdt( dvdtTypMinMax& aDest );
|
bool readRampdvdt( dvdtTypMinMax& aDest );
|
||||||
bool readRamp();
|
bool readRamp();
|
||||||
|
bool readModelSpec();
|
||||||
bool readWaveform( IbisWaveform* aDest, IBIS_WAVEFORM_TYPE aType );
|
bool readWaveform( IbisWaveform* aDest, IBIS_WAVEFORM_TYPE aType );
|
||||||
bool readString( std::string& aDest );
|
bool readString( std::string& aDest );
|
||||||
bool storeString( std::string& aDest, bool aMultiline );
|
bool storeString( std::string& aDest, bool aMultiline );
|
||||||
|
|
Loading…
Reference in New Issue