Skip to content

Commit

Permalink
Update.
Browse files Browse the repository at this point in the history
  • Loading branch information
ColinH committed Dec 17, 2020
1 parent 5d26c14 commit d9964d0
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 4 deletions.
6 changes: 3 additions & 3 deletions doc/Changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@

Released: 2020-12-17

* Added some experimental and undocumented `contrib` features.
* Added `test()` and `can_match_eol` members to pertinent rules.
* Made `analyze()` more verbose by default to aid finding the rule cycles.
* Added `parse_nested()` overload that accepts a `position` as first argument.
* Added some experimental and undocumented `contrib` features and their infrastructure.
* Improved CMake support for [`<filesystem>`](Installing-and-Using.md#filesystem) fallbacks and alternatives.
* Re-enabled support for GCC 7.
* Automatically link with `libstdc++fs` or `libc++fs` as needed.
* Added automatic fallback from `std::filesystem` to `std::experimental::filesystem` as needed.
* Added automatic fallback from `std::filesystem` to `std::experimental::filesystem`.
* Added manual fallback from `std::filesystem` to `boost::filesystem`.
* Thank you [Beman Dawes](https://isocpp.org/blog/2020/12/remembering-beman-dawes)!
* Converted continuous integration infrastructure to GitHub Actions.
Expand Down
14 changes: 13 additions & 1 deletion doc/Inputs-and-Parsing.md
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,7 @@ Nested parsing refers to an (inner) parsing run that is performed "in the middle
The difference to the regular `tao::pegtl::parse()` function is that `tao::pegtl::parse_nested()` takes care of adding to the `std::vector` of `tao::pegtl::position` objects in the exception class `tao::pegtl::parse_error`.
This allows generating error messages of the form "error in file F1 line L1 included from file F2 line L2...".
Calling `parse_nested()` requires one additional argument compared to `parse()`, the input from the outer parsing run as first argument.
Compared to `parse()`, calling `parse_nested()` requires either the input from the outer parsing run or the position as additional first argument.
Everything else remains the same.
```c++
Expand All @@ -327,6 +327,18 @@ template< typename Rule,
bool parse_nested( const OuterInput& oi,
ParseInput& in,
States&&... st );
template< typename Rule,
template< typename... > class Action = nothing,
template< typename... > class Control = normal,
apply_mode A = apply_mode::action,
rewind_mode M = rewind_mode::required,
typename OuterInput,
typename ParseInput,
typename... States >
bool parse_nested( position op,
ParseInput& in,
States&&... st );
```

## Incremental Input
Expand Down

0 comments on commit d9964d0

Please sign in to comment.