Packages / openSUSE Leap 15.6 / Development/Libraries/Perl / perl-Try-Tiny

Package: perl-Try-Tiny (0.30-1.17)

Minimal try/catch with proper preservation of $@

This module provides bare bones 'try'/'catch'/'finally' statements that are designed to minimize common mistakes with eval blocks, and NOTHING else. This is unlike TryCatch which provides a nice syntax and avoids adding another call stack layer, and supports calling 'return' from the 'try' block to return from the parent subroutine. These extra features come at a cost of a few dependencies, namely Devel::Declare and Scope::Upper which are occasionally problematic, and the additional catch filtering uses Moose type constraints which may not be desirable either. The main focus of this module is to provide simple and reliable error handling for those having a hard time installing TryCatch, but who still want to write correct 'eval' blocks without 5 lines of boilerplate each time. It's designed to work as correctly as possible in light of the various pathological edge cases (see BACKGROUND) and to be compatible with any style of error values (simple strings, references, objects, overloaded objects, etc). If the 'try' block dies, it returns the value of the last statement executed in the 'catch' block, if there is one. Otherwise, it returns 'undef' in scalar context or the empty list in list context. The following examples all assign '"bar"' to '$x': my $x = try { die "foo" } catch { "bar" }; my $x = try { die "foo" } || "bar"; my $x = (try { die "foo" }) // "bar"; my $x = eval { die "foo" } || "bar"; You can add 'finally' blocks, yielding the following: my $x; try { die 'foo' } finally { $x = 'bar' }; try { die 'foo' } catch { warn "Got a die: $_" } finally { $x = 'bar' }; 'finally' blocks are always executed making them suitable for cleanup code which cannot be handled using local. You can add as many 'finally' blocks to a given 'try' block as you like. Note that adding a 'finally' block without a preceding 'catch' block suppresses any errors. This behaviour is consistent with using a standalone 'eval', but it is not consistent with 'try'/'finally' patterns found in other programming languages, such as Java, Python, Javascript or C#. If you learnt the 'try'/'finally' pattern from one of these languages, watch out for this.

Package information

Homepage
[http://search.cpan.org/dist/Try-Tiny/]
License
MIT
Супровідник downstream-пакета
Невідомо: не зазначено в проіндексованому джерелі
Пакет джерела
[perl-Try-Tiny]
Software project
[perl-Try-Tiny]

Versions and downloads for perl-Try-Tiny

Version / releaseArchitecture / repositoryPackage sizeInstalled sizeFilesPublisher repository artifact
0.30-1.17leap-15.6 / ossnoarchopenSUSE Leap 15.6 · OSS · multi-architecture33 KiB37 KiBlist of filesperl-Try-Tiny-0.30-1.17.noarch.rpm
About these downloads

Кожен рядок: метадані індексу пакетів для однієї версії, архітектури, набору й репозиторію. Назви, URL і розміри зі джерела; посилання є змінним місцем отримання, не перерозповсюдженням OpenFactory.

Dependencies and recommendations for perl-Try-Tiny

  • dep: perl(:MODULE_COMPAT_5.26.1)

    Package not available

Шляхи файлів пакета (9)

Paths come from the repository package-file index for the observed builds. They describe archive/package associations, not every file that will exist on a running system after maintainer scripts, alternatives, generated state, diversions, or installation choices.

  • /usr/lib/perl5/vendor_perl/5.26.1/Try
  • /usr/lib/perl5/vendor_perl/5.26.1/Try/Tiny.pm
  • /usr/lib/perl5/vendor_perl/5.26.1/x86_64-linux-thread-multi
  • /usr/share/doc/packages/perl-Try-Tiny
  • /usr/share/doc/packages/perl-Try-Tiny/Changes
  • /usr/share/doc/packages/perl-Try-Tiny/CONTRIBUTING
  • /usr/share/doc/packages/perl-Try-Tiny/LICENCE
  • /usr/share/doc/packages/perl-Try-Tiny/README
  • /usr/share/man/man3/Try::Tiny.3pm.gz

Field source: openSUSE Leap 15.6 OSS

Відомі вразливості

У відстежуваних джерелах немає відповідних повідомлень.

Остання синхронізація:

[Каталог CVE]

Контрольні суми

Repository signatures authenticate metadata. Artifact hashing is recorded separately. Neither establishes package safety.

0.30-1.17 / noarchСпостережено Sep 1, 2026sha512 aea97575048e…a43f6df4Контрольна сума джерела

Metadata observed; artifact bytes were not independently fetched or hashed by this catalog import. The digest below is source-reported.

Контрольна сума джерела (sha512): aea97575048e20463f45615b9eada14bda164ec30ad21de9b75153cfe74a8ae29248009da764b91395824d23ebb8df1d328326dd7c27298b1adfc7eda43f6df4

Field source: openSUSE Leap 15.6 OSS

Джерела

  • Authoritative source; repository metadata signature verified

    Доказ підпису

    leap-15-6-oss-multiarch:ca2653101b9afba6656aea529109ba0c0f1ca1a92aa8614e7c887fda5264c230

    Repository-signature verification record
    Signed-object SHA-256
    ca2653101b9afba6656aea529109ba0c0f1ca1a92aa8614e7c887fda5264c230
    Signer fingerprint
    AD485664E901B867051AB15F35A2F86E29B700A4
    Keyring revision
    opensuse-project-signing-key.asc
    SHA-256 b5745739ebfb95b25b8e810f9bcb847fe750ccda598bd85f02f0e974599a6d7e
    Tool and policy
    gpgv (GnuPG) 2.4.9
    openfactory-software-catalog-signature-v1
    Verification time
    Sep 1, 2026
    Repository metadata hash linkage
    Result
    Recorded as verified; digest details unavailable

Використати цей пакет

OpenFactory може завантажити цю операційну систему у віртуальній машині браузера або почати збірку образу з рідною назвою пакета з цього запису.