One of the top priorities for Cadence contributors is to ensure Cadence guarantees future backward compatibility of smart contracts. This is a long-term process that started at the end of 2021, in which Cadence will achieve feature completeness so it doesn't require any maintenance issues in the future.Based on the feedback from the community so far, this milestone was separated into two phases:
- Secure Cadence: Already achieved! This centered on security hardening which unlocked permissionless smart contract deployment.
- Cadence Upgrade: Coming soon! This update focuses on usability & security improvements.
Initiatives
Cadence encourages the capability-based security model for resources. The existing API was confusing and awkward to use for developers. FLIP 798: Capability controllers is aimed at making capabilities developer friendly and easy to use.
Attachments are a feature of Cadence designed to allow developers to extend a struct or resource type with new functionality, without requiring the original author of the type to plan or account for the intended behavior. For example, imagine adding autographs to NBA TopShot moments or using CrypoKitties in a racing game.
Mutability Restrictions
A previous version of Cadence attempted to prevent a common safety foot-gun: Developers might use the let keyword for a container-typed field, assuming it would be immutable.
To make the smart contracts more secure, several improvements have been made at the language level to eliminate the mentioned foot gun, which were originally proposed in FLIP 89: Change Member Access Semantics and FLIP 86: Introduce Built-in Mutability Entitlements. These improvements are lined out in a vision document.
Invalidating references to transferred resources
By introducing the invalidation for ephemeral reference values in Cadence, a potential foot-gun of accidentally gaining or retaining resource access a user does not own can be avoided.
The new Entitlements feature allows developers to directly mark which fields and functions should be access-limited using new bespoke modifiers, and which should be generally available to anyone. It simplifies interacting with references significantly, as users would no longer be restricted from accessing methods like deposit that are safe for anyone to use, just because they do not possess a reference of the specific type, or because they are trying to write a generic method that works, say, on any NFT type.
Current progress
The next major upgrade of Cadence is expected to be released in early 2024, and the completion of this key milestone will ensure a resilient and stable decentralized smart contract platform for future generations. The upgrade path, network testing plan and tooling are still being explored with the community.
Roadmap goals
Keep reading
Quickstarts
Stay up to date with the latest news on Flow.
Stay up to date with the latest news on Flow.