question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

import * means wildcard with 3.0-migration

See original GitHub issue

Compiler version

3.0.0 (only tested in REPL)

Minimized code

// REPL with -source:3.0-migration
class Operations {
  def *(i: Int, j: Int) = i * j
  def println(any: Any): Unit = ???
}

object Main extends App {
  val ops = new Operations()
  import ops.*
  println(*(2, 3))
}

val _ = Main

Output

scala.NotImplementedError: an implementation is missing
  at scala.Predef$.$qmark$qmark$qmark(Predef.scala:345)
  at rs$line$1$Operations.println(rs$line$1:3)
  at rs$line$1$Main$.<clinit>(rs$line$1:9)

Expectation

print 6

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:6 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
som-snyttcommented, May 18, 2021

What is the corrective syntax?

import ops.`*`

?

0reactions
bishaboshacommented, Jun 22, 2021

my point here is that under 3.0-migration no “new syntax” should be allowed, so shouldn’t this behave as import foo.* would in scala 2?

edit it seems if then else is also allowed so maybe not (but enums are definitely not allowed)

Read more comments on GitHub >

github_iconTop Results From Across the Web

Migration Guide: SQL, Datasets and DataFrame - Apache Spark
Since Spark 3.3, when reading values from a JSON attribute defined as FloatType ... Since Spark 2.4, The LOAD DATA command supports wildcard...
Read more >
Cisco ISE: 3.0 Major Upgrade - LookingPoint
In our case, the deployment makes use of a shared, wildcard certificate. ... Of utmost import are the ISE EAP and Portal certificates...
Read more >
nestjs - Typeorm@0.3 unclear release documentation about ...
From this I get that we now must specify the entities and can not use (or better said, won't be able to use...
Read more >
Cisco ISE 3.0 Upgrade Guide: Upgrade Method
2. Import the new configuration file to the PAN UI. ... CA certificates from Secondary PAN unless you are using wild card certificates....
Read more >
A Classification of Proposed Language Features - Scala 3
Given Imports: implicits now require a special form of import, ... the other constructs in the list above are available only under -source...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found