Skip to content

Unhelpful "This old given syntax is no longer supported" warning #22785

Open
@slavaschmidt

Description

@slavaschmidt

Compiler version

3.6.4

Minimized example

sealed trait IsVal[A]:
  type V
  def cons(v: V): A
  def decons(a: A): V

abstract class Get[A]:
  def map[B](f: A => B): Get[B]

object Mappings:
  given [A](using wrapped: IsVal[A], get: Get[wrapped.V]): Get[A] = get.map(wrapped.cons)

Output Error/Warning message

This old given syntax is no longer supported; use `=>` instead of `:`
  given [A](using wrapped: IsVal[A], get: Get[wrapped.V]): Get[A] = get.map(wrapped.cons)

Why this Error/Warning was not helpful

The message was unhelpful because it does not show how to use the new syntax (or if it is possible at all).

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:reportingError reporting including formatting, implicit suggestions, etcbetter-errorsIssues concerned with improving confusing/unhelpful diagnostic messagesitype:enhancement

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions