Skip to content

Comment indicates side effect in method where none exists #114

@zellidev0

Description

@zellidev0

In the option.dart file a comment suggests that the code below the comment has side effects.

// PURISTS BEWARE: side effecty stuff below -- proceed with caution!

One Method there is the toNullable() method.

It looks like that:

A? toNullable() => fold(() => null, id);

This method does not seem to create a side effect and therefore it should be above the stated comment to avoid confusion.

I would create a PR that moves the method upwords, so that it is above the comment. Would this PR be merged?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions