throw Exception do not include "Error: " in what
This commit is contained in:
parent
ae61892d7d
commit
3277f1b1d6
|
|
@ -496,6 +496,11 @@ set_property(SOURCE ${STA_SWIG_FILE}
|
|||
-I${STA_HOME}/verilog
|
||||
)
|
||||
|
||||
set_property(SOURCE ${STA_SWIG_FILE}
|
||||
PROPERTY DEPENDS
|
||||
${STA_HOME}/tcl/Exception.i
|
||||
)
|
||||
|
||||
swig_add_library(sta_swig
|
||||
LANGUAGE tcl
|
||||
TYPE STATIC
|
||||
|
|
|
|||
|
|
@ -92,7 +92,7 @@ PropertyUnknown::PropertyUnknown(const char *type,
|
|||
const char *
|
||||
PropertyUnknown::what() const noexcept
|
||||
{
|
||||
return stringPrint("Error: %s objects do not have a %s property.",
|
||||
return stringPrint("%s objects do not have a %s property.",
|
||||
type_, property_);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -239,7 +239,7 @@ SubcktEndsMissing::SubcktEndsMissing(const char *cell_name,
|
|||
const char *subckt_filename) :
|
||||
Exception()
|
||||
{
|
||||
what_ = "Error: spice subckt for cell ";
|
||||
what_ = "spice subckt for cell ";
|
||||
what_ += cell_name;
|
||||
what_ += " missing .ends in ";
|
||||
what_ += subckt_filename;
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@
|
|||
exit(0);
|
||||
}
|
||||
catch (std::exception &excp) {
|
||||
Tcl_SetResult(interp, const_cast<char*>(excp.what()), TCL_VOLATILE);
|
||||
Tcl_AppendResult(interp, "Error: ", excp.what(), nullptr);
|
||||
return TCL_ERROR;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -90,7 +90,7 @@ proc check_for_key_args { cmd arg_var } {
|
|||
while { $args != "" } {
|
||||
set arg [lindex $args 0]
|
||||
if { [is_keyword_arg $arg] } {
|
||||
sta_warn "$cmd $arg is not a known keyword or flag."
|
||||
sta_error "$cmd $arg is not a known keyword or flag."
|
||||
} else {
|
||||
lappend args_rtn $arg
|
||||
}
|
||||
|
|
|
|||
|
|
@ -58,7 +58,7 @@ FileNotReadable::FileNotReadable(const char *filename) :
|
|||
const char *
|
||||
FileNotReadable::what() const noexcept
|
||||
{
|
||||
return stringPrintTmp("Error: cannot read file %s.", filename_);
|
||||
return stringPrintTmp("cannot read file %s.", filename_);
|
||||
}
|
||||
|
||||
FileNotWritable::FileNotWritable(const char *filename) :
|
||||
|
|
@ -69,7 +69,7 @@ FileNotWritable::FileNotWritable(const char *filename) :
|
|||
const char *
|
||||
FileNotWritable::what() const noexcept
|
||||
{
|
||||
return stringPrintTmp("Error: cannot write file %s.", filename_);
|
||||
return stringPrintTmp("cannot write file %s.", filename_);
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
|
|
|||
Loading…
Reference in New Issue