Skip to content
This repository has been archived by the owner on Aug 2, 2022. It is now read-only.

block_timestamp::maximum returns a small value #1204

Open
tbfleming opened this issue Sep 3, 2021 · 0 comments
Open

block_timestamp::maximum returns a small value #1204

tbfleming opened this issue Sep 3, 2021 · 0 comments
Assignees

Comments

@tbfleming
Copy link
Contributor

block_timestamp::maximum has this incorrect definition:

static block_timestamp maximum() { return block_timestamp( 0xffff ); }

I recommend the following:

  • Remove this function
  • Create a replacement with a different name (e.g. max()) to prevent existing contracts that rely on maximum from changing behavior. Contracts which rely on the incorrect behavior will fail to build, notifying the authors of the potentially serious problem.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants