tparameterizedparent0.nim 247 B

12345678910111213141516
  1. discard """
  2. errormsg: "inheritance only works with non-final objects"
  3. file: "tparameterizedparent0.nim"
  4. line: 14
  5. """
  6. # bug #5264
  7. type
  8. Kapal* = enum
  9. Besar
  10. Apple[T] = object of T
  11. color: int
  12. var x = Apple[Kapal](color: 13)
  13. echo x