X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=lily%2Flily-parser.cc;h=35e030951043bd2c4218d2c5c96b15ea5ad2858e;hb=47db9a3883d726ca53e2133a3b2298f78dd6a32e;hp=fd1eb489816956d37824aabb2cc07c61d4b4029d;hpb=00b9619cea1020f6773f23df8764ef85ee2912bf;p=lilypond.git diff --git a/lily/lily-parser.cc b/lily/lily-parser.cc index fd1eb48981..35e0309510 100644 --- a/lily/lily-parser.cc +++ b/lily/lily-parser.cc @@ -1,7 +1,7 @@ /* This file is part of LilyPond, the GNU music typesetter. - Copyright (C) 1997--2014 Han-Wen Nienhuys + Copyright (C) 1997--2015 Han-Wen Nienhuys Jan Nieuwenhuizen LilyPond is free software: you can redistribute it and/or modify @@ -54,6 +54,7 @@ Lily_parser::Lily_parser (Sources *sources) } Lily_parser::Lily_parser (Lily_parser const &src, SCM closures, SCM location) + : Smob () { lexer_ = 0; sources_ = src.sources_; @@ -83,12 +84,11 @@ Lily_parser::mark_smob () } int -Lily_parser::print_smob (SCM s, SCM port, scm_print_state *) +Lily_parser::print_smob (SCM port, scm_print_state *) { scm_puts ("#lexer_) - scm_display (parser->lexer_->self_scm (), port); + if (lexer_) + scm_display (lexer_->self_scm (), port); else scm_puts ("(no lexer yet)", port); scm_puts (" >", port);