title: How to access parameter list of case class in a dotty macro
body: <p>I am trying to learn meta-programming in dotty. Specifically compile time code generation. I thought learning by building something would be a good approach. So I decided to make a CSV parser which will parse lines into case classes. I want to use dotty macros to generate decoders</p>
  <pre><code>trait Decoder[T]{
    def decode(str:String):Either[ParseError, T]
  }
  
  object Decoder {
    inline given stringDec as Decoder[String] = new Decoder[String] {
      override def decode(str: String): Either[ParseError, String] = Right(str)
    }
  
    inline given intDec as Decoder[Int] = new Decoder[Int] {
      override def decode(str: String): Either[ParseError, Int] =
        str.toIntOption.toRight(ParseError(str, &quot;value is not valid Int&quot;))
    }
    
    inline def forType[T]:Decoder[T] = ${make[T]}
  
    def make[T:Type](using qctx: QuoteContext):Expr[Decoder[T]] = ???
  }
  </code></pre>
  <p>I have provided basic decoders for <code>Int</code> &amp; <code>String</code>, now I looking for guidance for <code>def make[T:Type]</code> method. How to iterate parameter list of a case class <code>T</code> inside this method? Are there any recommended ways or patterns to do this?</p>