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

Useful Quickfixes that are missing #356

@jthoene

Description

@jthoene
  • msg.gas -> gasleft() : msg.gas has been deprecated in favor of gasleft()
  • change type "address" of variable to "address payable" if the "send" or "transfer" function is used for this variable: "send" and "transfer" are only available for objects of type "address payable", not "address".
  • make function payable for the following compiler error: "msg.value" and "callvalue()" can only be used in payable public functions. Make the function "payable" or use an internal function to avoid this error.
  • Add datalocation for return parameters: Data location must be "memory" or "calldata" for return parameter in function, but none was given.
  • Add datalocation for variables: Data location must be "storage", "memory" or "calldata" for variable, but none was given. - Change "block.blockhash()" to "blockhash()": "block.blockhash()" has been deprecated in favor of "blockhash()"
  • Make contract abstract: Contract "xxxx" should be marked as abstract.
  • Mark function as virtual: Functions without implementation must be marked virtual.
  • Add override keyword for functions, which override a method: Overriding function is missing "override" specifier.

Metadata

Metadata

Assignees

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