diff options
| author | Jakub Konka <kubkon@jakubkonka.com> | 2022-01-31 17:07:45 +0100 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2022-01-31 22:29:29 -0500 |
| commit | 627cf6ce482349c172150d058660f7a1646c2aac (patch) | |
| tree | f786071370621bca7f51e95e4a35c626083b3de8 /src/stage1/codegen.cpp | |
| parent | abbcf4032770676aee0e4a37f19d9e9ad2bdd992 (diff) | |
| download | zig-627cf6ce482349c172150d058660f7a1646c2aac.tar.gz zig-627cf6ce482349c172150d058660f7a1646c2aac.zip | |
astgen: clean up source line calculation and management
Clarify that `astgen.advanceSourceCursor` already increments absolute
values of the line and columns numbers; i.e., `GenZir.calcLine` is thus
not only obsolete but wrong by design.
Incidentally, this clean up allows for specifying the `FnDecl` line
numbers for DWARF use correctly as relative values with respect to
the start of the parent `Decl`. This `Decl` in turn has its line number
information specified relatively to its parent `Decl`, and so on, until
we reach the global scope.
Diffstat (limited to 'src/stage1/codegen.cpp')
0 files changed, 0 insertions, 0 deletions
