Skip to content

Structural types in extends clause #258

Closed
@susliko

Description

@susliko

Commit of tree-sitter-scala you tested this on

374709c

A code sample showing the error

object namerFactory extends {
  val a: A = b
} 

Show the error node

(compilation_unit [0, 0] - [4, 0]
  (object_definition [0, 0] - [2, 1]
    name: (identifier [0, 7] - [0, 19])
    (ERROR [0, 20] - [0, 27])
    body: (template_body [0, 28] - [2, 1]
      (val_definition [1, 2] - [1, 14]
        pattern: (identifier [1, 6] - [1, 7])
        type: (type_identifier [1, 9] - [1, 10])
        value: (identifier [1, 13] - [1, 14])))))

What do you expect the tree to look like

No response

Where are you experiencing this error?

Reading Scala compiler code is like reading some ancient scrolls:
Analyzer.scala

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions