Skip to content

/*/* not recognized as a double comment opening #1152

Closed
@sjrd

Description

@sjrd

The following code:

package hello

object world extends App {
  println("hello dotty!")
  /*/* one
  */
  two
  */
  println("foo")
}

fails to compile with

[error] examples/hello.scala:7: error: not found: two
[error]   two
[error]   ^
[error] examples/hello.scala:8: error: not found: */
[error]   */
[error]   ^
[error] two errors found

So, apparently, the opening /*/* is considered as a single comment opening instead of two.

Inserting a space in /* /* works around the issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions