Tag

try-finally

1 views collected around this technical thread.

JavaScript
JavaScript
May 28, 2025 · Frontend Development

Simplify JavaScript Resource Management with the New ‘using’ Declaration

This article explains why the traditional try‑finally pattern for resource handling in JavaScript is verbose and error‑prone, and introduces the upcoming ECMAScript ‘using’ declaration that provides automatic, scope‑based cleanup, supports async resources, and makes code cleaner and safer.

ECMAScriptJavaScriptresource management
0 likes · 2 min read
Simplify JavaScript Resource Management with the New ‘using’ Declaration
Selected Java Interview Questions
Selected Java Interview Questions
May 23, 2021 · Fundamentals

Analyzing Java try‑finally and try‑catch‑finally Execution Through Bytecode

The article examines how the Java Virtual Machine compiles try‑finally and try‑catch‑finally constructs, shows the generated bytecode with javap, explains the execution order both when no exception occurs and when an exception is thrown, and highlights the impact of return statements inside try blocks.

BytecodeJVMJava
0 likes · 6 min read
Analyzing Java try‑finally and try‑catch‑finally Execution Through Bytecode
Python Programming Learning Circle
Python Programming Learning Circle
Apr 8, 2020 · Fundamentals

Understanding Python Dictionary Keys, Return Behavior in try/finally, and Object Identity

This article explains why Python dictionary keys with numeric values can overwrite each other, how a return statement inside a try block is overridden by a return in a finally block, and why object identity (is) and hash values behave as they do, illustrating each point with code examples.

Fundamentalsdictionaryhash
0 likes · 4 min read
Understanding Python Dictionary Keys, Return Behavior in try/finally, and Object Identity