Dispose Blocks Pattern is a language feature.
To make the safe use of the dispose pattern less verbose, several languages have some kind of built-in support for resources held and released in the same block of code.
Languages without Dispose Blocks Pattern include Ruby
Languages with Dispose Blocks Pattern include Python, C#
with resource_context_manager() as resource:
# Perform actions with the resource.
# Perform other actions where the resource is guaranteed to be deallocated.
using (Resource resource = GetResource())
{
// Perform actions with the resource.
...
}