From bb914f047b0d96464f3e55234907df4e7c416e97 Mon Sep 17 00:00:00 2001 From: Loic Guegan Date: Wed, 26 Jan 2022 12:03:24 +0100 Subject: - Enable NAG parsing - Add the LargeFileStream interface to handle large file - Debug parsing --- src/HalfMove.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'src/HalfMove.cpp') diff --git a/src/HalfMove.cpp b/src/HalfMove.cpp index 290587a..7e94ef9 100644 --- a/src/HalfMove.cpp +++ b/src/HalfMove.cpp @@ -19,8 +19,8 @@ std::string HalfMove::NestedDump(HalfMove *m, int indent) { ss << " " << " Move=" << m->move << " Count=" << m->count << " Comment=\"" << m->comment << "\"" - << " IsBlack=" << m->isBlack << " Variations=" << m->variations.size() - << std::endl; + << " NAG=" << m->NAG << " IsBlack=" << m->isBlack + << " Variations=" << m->variations.size() << std::endl; for (auto *var : m->variations) { ss << NestedDump(var, indent + 1); @@ -65,15 +65,15 @@ void HalfMove::Copy(HalfMove *copy) { } HalfMove *HalfMove::GetHalfMoveAt(int distance) { - HalfMove *tmp=this; - while(distance>0){ - if(tmp==NULL){ + HalfMove *tmp = this; + while (distance > 0) { + if (tmp == NULL) { throw HalfMoveOutOfRange(); } distance--; - tmp=tmp->MainLine; + tmp = tmp->MainLine; } - return(tmp); + return (tmp); } } // namespace pgnp \ No newline at end of file -- cgit v1.2.3