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

Discarded non-Unit value? #91

Description

@michalrus

Take this code:

var button = slot[Button]
button <~ On.click { button <~ hide }

… and compile it with -Ywarn-value-discard (useful flag!) using the 2.11.8 compiler.

It fails with:

[error] /home/m/Development/[…]/TestActivity.scala:19: discarded non-Unit value
[error]     button <~ On.click { button <~ show }
[error]                        ^
[error] one error found

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions