Skip to content
This repository has been archived by the owner on May 4, 2024. It is now read-only.

[Feature Request] Improve documentation/error message about trailing semicolon #141

Open
wrwg opened this issue May 15, 2022 · 0 comments
Open
Assignees
Labels
enhancement New feature or request

Comments

@wrwg
Copy link
Member

wrwg commented May 15, 2022

馃殌 Feature Request

Given the example:

fun f(){return;}

... the compiler reports

adding a semicolon implicitly adds '()' value after the semicolon. That value '()' will not be reachable

But the documentation says:

The unit value '()' does not result in any runtime value ( https://diem.github.io/move/tuples.html )

This is confusing, specifically for new users which are not acquainted with the Rust-style syntax of Move,

[Collected from Aptos user forum]

@wrwg wrwg added the enhancement New feature or request label May 15, 2022
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

No branches or pull requests

2 participants