From bac26647e4febc81786565b02468f122c5a26b11 Mon Sep 17 00:00:00 2001 From: Nicolas Sceaux Date: Sun, 16 Nov 2008 20:45:37 +0100 Subject: [PATCH] Nested bookparts: fix $papers pop in case of \book block with identifier --- lily/lily-parser.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lily/lily-parser.cc b/lily/lily-parser.cc index c46224fbbc..afd401baa9 100644 --- a/lily/lily-parser.cc +++ b/lily/lily-parser.cc @@ -257,8 +257,9 @@ push_paper (Lily_parser *parser, Output_def *paper) void pop_paper (Lily_parser *parser) { - parser->lexer_->set_identifier (ly_symbol2scm ("$papers"), - scm_cdr (parser->lexer_->lookup_identifier ("$papers"))); + if (! scm_is_null (parser->lexer_->lookup_identifier ("$papers"))) + parser->lexer_->set_identifier (ly_symbol2scm ("$papers"), + scm_cdr (parser->lexer_->lookup_identifier ("$papers"))); } /* Change the paper on top of $papers stack */ -- 2.39.5