From 2d8fc5a2c425774f6239134990c91de22955add5 Mon Sep 17 00:00:00 2001 From: Ko van der Sloot Date: Thu, 28 Nov 2024 08:44:09 +0100 Subject: [PATCH] added some more debugging --- src/folia_impl.cxx | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/src/folia_impl.cxx b/src/folia_impl.cxx index 6fe1e13..6deb2d9 100644 --- a/src/folia_impl.cxx +++ b/src/folia_impl.cxx @@ -2186,17 +2186,28 @@ namespace folia { } return EMPTY_STRING; } + if ( tp.debug() ){ + DBG << " space = YES, Go on" << endl; + } } if ( !_data.empty() ){ const FoliaElement *last = _data.back(); - if ( last && - last->isSubClass(AbstractStructureElement_t) + if ( last && tp.debug() ){ + DBG << "last is " << last << endl; + DBG << "isSubClass(AbstractStructure) == " << last->isSubClass(AbstractStructureElement_t) << endl; + DBG << "last->space() == " << last->space() << endl; + } + if ( last + && last->isSubClass(AbstractStructureElement_t) && !last->space() ){ return EMPTY_STRING; } } if ( text_delimiter() != "NONE" ) { + if ( tp.debug() ){ + DBG << "text_delimiter() == '" << text_delimiter() << "'" << endl; + } return text_delimiter(); } else if ( _data.size() > 0 ) {