25

This is a discussion on Python's forums about adding something akin to a throws keyword in python.

you are viewing a single comment's thread
view the rest of the comments
[-] qwertyasdef@programming.dev 8 points 10 months ago

Hey, I like checked exceptions too! I honestly think it's one of Javas's best features but it's hindered by the fact that try-catch is so verbose, libraries aren't always sensible about what exceptions they throw, and methods aren't exception-polymorphic for stuff like the Stream API. Which is to say, checked exceptions are a pain but that's the fault of the rest of the language around them and not the checked exceptions per se.

this post was submitted on 15 Nov 2023
25 points (87.9% liked)

Python

6174 readers
10 users here now

Welcome to the Python community on the programming.dev Lemmy instance!

📅 Events

October 2023

November 2023

PastJuly 2023

August 2023

September 2023

🐍 Python project:
💓 Python Community:
✨ Python Ecosystem:
🌌 Fediverse
Communities
Projects
Feeds

founded 1 year ago
MODERATORS