From 1b5a4718aa33901f8dd8ed4be46e34a1541642e5 Mon Sep 17 00:00:00 2001 From: Raymond Dodge Date: Thu, 28 Nov 2024 01:02:44 -0500 Subject: [PATCH] [base] Add a description to `<~`, `~>`, and `<::>` doccomments --- Base/src/main/scala/Extractor.scala | 4 ++++ Base/src/main/scala/Interpolator.scala | 6 ++++++ Base/src/main/scala/Parser.scala | 4 ++++ 3 files changed, 14 insertions(+) diff --git a/Base/src/main/scala/Extractor.scala b/Base/src/main/scala/Extractor.scala index 55830e8..f30fcff 100644 --- a/Base/src/main/scala/Extractor.scala +++ b/Base/src/main/scala/Extractor.scala @@ -153,6 +153,8 @@ final class Extractor[Expr[_], Type[_], -A] private[stringContextParserCombinato this.andThen(rhs)(ev) /** + * Returns a parser which invokes this parser, and upon success invokes the other parser, + * discarding the Unit result from the other parser * @group Sequence * @since 0.1.1 */ @@ -160,6 +162,8 @@ final class Extractor[Expr[_], Type[_], -A] private[stringContextParserCombinato this.andThen(rhs)(typeclass.ContraSequenced.genericUnit) /** + * Returns a parser which invokes this parser, and upon success invokes the other parser, + * discarding the Unit result from this parser * @group Sequence * @since 0.1.1 */ diff --git a/Base/src/main/scala/Interpolator.scala b/Base/src/main/scala/Interpolator.scala index 528f39e..4f95d1f 100644 --- a/Base/src/main/scala/Interpolator.scala +++ b/Base/src/main/scala/Interpolator.scala @@ -189,6 +189,8 @@ final class Interpolator[-Expr, +A] private[stringContextParserCombinator] ( this.andThen(rhs)(ev) /** + * Returns a parser which invokes this parser, and upon success invokes the other parser, + * discarding the Unit result from the other parser * @group Sequence * @since 0.1.1 */ @@ -196,6 +198,8 @@ final class Interpolator[-Expr, +A] private[stringContextParserCombinator] ( this.andThen(rhs)(typeclass.Sequenced.genericUnit) /** + * Returns a parser which invokes this parser, and upon success invokes the other parser, + * discarding the Unit result from this parser * @group Sequence * @since 0.1.1 */ @@ -203,6 +207,8 @@ final class Interpolator[-Expr, +A] private[stringContextParserCombinator] ( this.map(ev).andThen(rhs)(typeclass.Sequenced.unitGeneric) /** + * Returns a parser which invokes this parser, and upon success invokes the other parser, + * prepending the result from this parser to the List result from the other parser * @group Sequence * @since 0.1.1 */ diff --git a/Base/src/main/scala/Parser.scala b/Base/src/main/scala/Parser.scala index f06df4e..967c23b 100644 --- a/Base/src/main/scala/Parser.scala +++ b/Base/src/main/scala/Parser.scala @@ -154,6 +154,8 @@ final class Parser[Expr[_], Type[_], A] private[stringContextParserCombinator] ( this.andThen(rhs)(ev) /** + * Returns a parser which invokes this parser, and upon success invokes the other parser, + * discarding the Unit result from the other parser * @group Sequence * @since 0.1.1 */ @@ -161,6 +163,8 @@ final class Parser[Expr[_], Type[_], A] private[stringContextParserCombinator] ( this.andThen(rhs)(typeclass.BiSequenced.genericUnit) /** + * Returns a parser which invokes this parser, and upon success invokes the other parser, + * discarding the Unit result from this parser * @group Sequence * @since 0.1.1 */