]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
Fix error messages when using preprocessing directives
authorJürg Billeter <j@bitron.ch>
Sun, 5 Apr 2009 16:42:25 +0000 (18:42 +0200)
committerJürg Billeter <j@bitron.ch>
Sun, 5 Apr 2009 16:42:25 +0000 (18:42 +0200)
The line information was off when skipping conditional sections.

vala/valascanner.vala

index ec9e907b021d10a32be2774b3354301d07a1885c..4177fb84d88360b6dd9dbaa715cdfc59525bf3ae 100644 (file)
@@ -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') {