dlang-community / libdparse

Library for lexing and parsing D source code
https://libdparse.dlang.io
Boost Software License 1.0
114 stars 56 forks source link

attach token location to error tokens #483

Closed WebFreak001 closed 1 year ago

WebFreak001 commented 1 year ago

Makes invalid strings error at proper location instead of at 0,0

See confusion in https://forum.dlang.org/post/mcaldhecyexsolqoctsy@forum.dlang.org

codecov[bot] commented 1 year ago

Codecov Report

Merging #483 (8cb897f) into master (88f247e) will increase coverage by 0.25%. The diff coverage is 94.00%.

Additional details and impacted files [![Impacted file tree graph](https://codecov.io/gh/dlang-community/libdparse/pull/483/graphs/tree.svg?width=650&height=150&src=pr&token=VHoPCaUjPZ&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dlang-community)](https://codecov.io/gh/dlang-community/libdparse/pull/483?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dlang-community) ```diff @@ Coverage Diff @@ ## master #483 +/- ## ========================================== + Coverage 83.20% 83.45% +0.25% ========================================== Files 11 11 Lines 8423 8454 +31 ========================================== + Hits 7008 7055 +47 + Misses 1415 1399 -16 ``` | [Impacted Files](https://codecov.io/gh/dlang-community/libdparse/pull/483?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dlang-community) | Coverage Δ | | |---|---|---| | [src/dparse/lexer.d](https://codecov.io/gh/dlang-community/libdparse/pull/483?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dlang-community#diff-c3JjL2RwYXJzZS9sZXhlci5k) | `87.85% <94.00%> (+2.18%)` | :arrow_up: | | [src/std/experimental/lexer.d](https://codecov.io/gh/dlang-community/libdparse/pull/483?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dlang-community#diff-c3JjL3N0ZC9leHBlcmltZW50YWwvbGV4ZXIuZA==) | `79.48% <0.00%> (-5.13%)` | :arrow_down: | ------ [Continue to review full report at Codecov](https://codecov.io/gh/dlang-community/libdparse/pull/483?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dlang-community). > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dlang-community) > `Δ = absolute (impact)`, `ø = not affected`, `? = missing data` > Powered by [Codecov](https://codecov.io/gh/dlang-community/libdparse/pull/483?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dlang-community). Last update [88f247e...8cb897f](https://codecov.io/gh/dlang-community/libdparse/pull/483?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dlang-community). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dlang-community).