diff --git a/build.sbt b/build.sbt index e8e8e981..82eb198a 100644 --- a/build.sbt +++ b/build.sbt @@ -4,7 +4,7 @@ ThisBuild / startYear := Some(2004) val commonSettings = Seq( versionScheme := Some("early-semver"), versionPolicyIntention := Compatibility.BinaryAndSourceCompatible, - crossScalaVersions := Seq("2.13.14", "2.12.20", "3.3.4"), + crossScalaVersions := Seq("2.13.15", "2.12.20", "3.3.4"), scalaVersion := crossScalaVersions.value.head, ) diff --git a/shared/src/main/scala/scala/util/parsing/combinator/lexical/StdLexical.scala b/shared/src/main/scala/scala/util/parsing/combinator/lexical/StdLexical.scala index d5bdbdbf..a5f8a7ab 100644 --- a/shared/src/main/scala/scala/util/parsing/combinator/lexical/StdLexical.scala +++ b/shared/src/main/scala/scala/util/parsing/combinator/lexical/StdLexical.scala @@ -17,6 +17,7 @@ package lexical import token._ import input.CharArrayReader.EofCh +import scala.annotation.nowarn import scala.collection.mutable /** This component provides a standard lexical parser for a simple, @@ -54,6 +55,7 @@ class StdLexical extends Lexical with StdTokens { } // see `whitespace in `Scanners` + @nowarn("cat=lint-infer-any") def whitespace: Parser[Any] = rep[Any]( whitespaceChar | '/' ~ '*' ~ comment diff --git a/shared/src/test/scala/scala/util/parsing/combinator/PackratParsersTest.scala b/shared/src/test/scala/scala/util/parsing/combinator/PackratParsersTest.scala index 3918b4f8..07df04ec 100644 --- a/shared/src/test/scala/scala/util/parsing/combinator/PackratParsersTest.scala +++ b/shared/src/test/scala/scala/util/parsing/combinator/PackratParsersTest.scala @@ -222,7 +222,7 @@ private object grammars3 extends StandardTokenParsers with PackratParsers { | success(Nil) ) - @annotation.nowarn // Some(xs) in pattern isn't exhaustive + @annotation.nowarn("cat=other-match-analysis") def repMany1[T](p: => Parser[T], q: => Parser[T]): Parser[List[T]] = p~opt(repMany(p,q))~q ^^ {case x~Some(xs)~y => x::xs:::(y::Nil)}