[vala] Fix error messages when using preprocessing directives



commit 5cd3e70a7bb0594dfb811c627b9907124d6b26bb
Author: Jürg Billeter <j bitron ch>
Date:   Sun Apr 5 18:42:25 2009 +0200

    Fix error messages when using preprocessing directives
    
    The line information was off when skipping conditional sections.
---
 vala/valascanner.vala |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/vala/valascanner.vala b/vala/valascanner.vala
index ec9e907..4177fb8 100644
--- a/vala/valascanner.vala
+++ b/vala/valascanner.vala
@@ -828,8 +828,8 @@ public class Vala.Scanner {
 			while (current < end) {
 				if (bol && current[0] == '#') {
 					// go back to begin of line
-					current -= column;
-					column = 0;
+					current -= (column - 1);
+					column = 1;
 					return;
 				}
 				if (current[0] == '\n') {



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]