From 7007d21135dd98d1da6a50de4fa88706590eb211 Mon Sep 17 00:00:00 2001 From: Noya2 <107465724+noya2ruler@users.noreply.github.com> Date: Tue, 4 Jun 2024 19:39:14 +0900 Subject: [PATCH] =?UTF-8?q?=E5=91=A8=E8=BE=BA=E3=81=AE=E3=83=86=E3=82=AD?= =?UTF-8?q?=E3=82=B9=E3=83=88=E3=81=A8=E3=81=97=E3=81=A6=E8=A1=8C=E5=85=A8?= =?UTF-8?q?=E4=BD=93=E3=82=92=E8=BF=94=E3=81=99=E3=82=88=E3=81=86=E3=81=AB?= =?UTF-8?q?=E4=BF=AE=E6=AD=A3=E3=81=97=E3=81=9F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/reader.hpp | 2 +- src/syntax/EnumerateBlock.hpp | 2 +- src/syntax/ListBlock.hpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/reader.hpp b/src/reader.hpp index 53e31b1..e4a243a 100644 --- a/src/reader.hpp +++ b/src/reader.hpp @@ -73,7 +73,7 @@ struct Reader { if (row > 0){ ret += lines[row-1] + "\n"; } - ret += lines[row].substr(0,col); + ret += lines[row]; return ret; } }; diff --git a/src/syntax/EnumerateBlock.hpp b/src/syntax/EnumerateBlock.hpp index e49e101..fb6d9f5 100644 --- a/src/syntax/EnumerateBlock.hpp +++ b/src/syntax/EnumerateBlock.hpp @@ -120,7 +120,7 @@ struct EnumerateBlockSyntax : public BlockSyntax { // depth has decreased and the difference is multiple of 3 if (depth < current && (current - depth) % 3 == 0) return true; // ambiguous enum definition detected - std::cerr << "Warning near '" << read.near() << "'" << std::endl; + std::cerr << "Warning: ambiguous enum\n ... \n" << read.near() << "\n^^^ parsing line" << std::endl; std::cerr << "indent width must be 3. this line is considered as raw text." << std::endl; return false; }()){ diff --git a/src/syntax/ListBlock.hpp b/src/syntax/ListBlock.hpp index 976d434..b889586 100644 --- a/src/syntax/ListBlock.hpp +++ b/src/syntax/ListBlock.hpp @@ -111,7 +111,7 @@ struct ListBlockSyntax : public BlockSyntax { // depth has decreased and the difference is even if (depth < current && (current - depth) % 2 == 0) return true; // ambiguous list definition detected - std::cerr << "Warning near '" << read.near() << "'" << std::endl; + std::cerr << "Warning: ambiguous list\n ... \n" << read.near() << "\n^^^ parsing line" << std::endl; std::cerr << "indent width must be 2. this line is considered as raw text." << std::endl; return false; }()){