Class

scala.annotation

compileTimeOnly

Related Doc: package annotation

Permalink

final class compileTimeOnly extends Annotation with StaticAnnotation

An annotation that designates that an annottee should not be referred to after type checking (which includes macro expansion).

Examples of potential use: 1) The annottee can only appear in the arguments of some other macro that will eliminate it from the AST during expansion. 2) The annottee is a macro and should have been expanded away, so if hasn't, something wrong has happened. (Comes in handy to provide better support for new macro flavors, e.g. macro annotations, that can't be expanded by the vanilla compiler).

Annotations
@getter() @setter() @beanGetter() @beanSetter() @companionClass() @companionMethod()
Source
compileTimeOnly.scala
Since

2.11.0

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. compileTimeOnly
  2. StaticAnnotation
  3. Annotation
  4. AnyRef
  5. Any
Implicitly
  1. by any2stringadd
  2. by StringFormat
  3. by Ensuring
  4. by ArrowAssoc
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new compileTimeOnly(message: String)

    Permalink

    message

    the error message to print during compilation if a reference remains after type checking