Confirming that issue #1282 is fixed

This commit is contained in:
Matthias Koefferlein 2023-02-17 00:02:59 +01:00
parent 33c858924f
commit 4eb48738e4
2 changed files with 12 additions and 4 deletions

View File

@ -404,14 +404,14 @@ LEFImporter::read_nondefaultrule (db::Layout &layout)
// read NONDEFAULTRULE sections
std::string n = get ();
while (! test ("END")) {
while (! at_end () && ! test ("END")) {
if (test ("LAYER")) {
std::string l = get ();
// read the width for the layer
while (! test ("END")) {
while (! at_end () && ! test ("END")) {
if (test ("WIDTH")) {
double w = get_double ();
test (";");
@ -452,7 +452,7 @@ LEFImporter::read_nondefaultrule (db::Layout &layout)
void
LEFImporter::read_viadef_by_rule (RuleBasedViaGenerator *vg, ViaDesc &via_desc, const std::string & /*n*/, double dbu)
{
while (! test ("END")) {
while (! at_end () && ! test ("END")) {
double x, y;
@ -1181,7 +1181,7 @@ LEFImporter::do_read (db::Layout &layout)
LEFDEFSection section (this, "BEGINEXT");
// read over BEGINEXT sections
while (! test ("ENDEXT")) {
while (! at_end () && ! test ("ENDEXT")) {
take ();
}

View File

@ -320,6 +320,7 @@ TEST(lef7)
TEST(lef8)
{
// this is rather a smoke test and throws a number of warnings
// (complete example)
run_test (_this, "lef8", "lef:tech.lef+lef:a.lef", "au.oas.gz", default_options ());
}
@ -425,6 +426,7 @@ TEST(def15)
TEST(def16)
{
// this is rather a smoke test
// (complete example)
db::LEFDEFReaderOptions opt = default_options ();
opt.set_macro_resolution_mode (1);
run_test (_this, "def16", "lef:a.lef+lef:tech.lef+def:a.def", "au.oas.gz", opt);
@ -968,3 +970,9 @@ TEST(205_lef_resistance)
run_test (_this, "issue-1214", "read:merged.nom.lef", "au.oas.gz", lefdef_opt, false);
}
// issue 1282
TEST(206_lef_spacing)
{
run_test (_this, "issue-1282", "read:a.lef", 0, default_options (), false);
}