Skip to content
This repository was archived by the owner on Jul 30, 2024. It is now read-only.

[console] Allow passing scala.Any to console #299

Merged
merged 3 commits into from
Jul 30, 2020
Merged

[console] Allow passing scala.Any to console #299

merged 3 commits into from
Jul 30, 2020

Conversation

exoego
Copy link
Owner

@exoego exoego commented Jul 30, 2020

Close #296

@exoego exoego added the enhancement New feature or request label Jul 30, 2020
@exoego exoego changed the title [console] Allow passing Any to console [console] Allow passing scala.Any to console Jul 30, 2020
@exoego
Copy link
Owner Author

exoego commented Jul 30, 2020

This does not compile on Scala 2.12... 🤔
Will revisitt when dropping Scala 2.12.

[error] both method log in class Console of type (data: Any)Unit
[error] and  method log in class Console of type (data: Any, args: Any*)Unit
[error] match argument types (io.scalajs.nodejs.console_module.ScalaNativeObject)
[error] Error occurred in an application involving default arguments.
[error]     Console.log(ScalaNativeObject(1))

Workaround: db1e9fa

@exoego exoego marked this pull request as draft July 30, 2020 08:03
@exoego exoego marked this pull request as ready for review July 30, 2020 11:46
@exoego exoego merged commit a2469df into master Jul 30, 2020
@exoego exoego deleted the any-logging branch July 30, 2020 12:41
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[console] Allow passing Scala-native object to logging method
1 participant