Verilog::Netlist::Logger(3pm)

Verilog::Netlist::Logger3pm

Error collection and reporting

Usage

  use Verilog::Netlist::Logger;
  ...
  my $self = Verilog::Netlist::Logger->new();
  $self->info("We're here\n");
  $self->warn("Things look bad\n");
  $self->error("Things are even worse\n");
  $self->exit_if_error();

Overview

The Verilog::Netlist::Logger is used to report all errors detected by Verilog::Netlist::* structures. By default, Verilog::Netlist creates a new Logger object, and passes it down to all contained objects. Users may create their own logger objects to catch or otherwise handle error messages.

Member functions

$self->error(object, Text...)

Print an error about the object in a standard format. The object must have a fileline method.

$self->exit_if_error([allow=>'warning'])

Exits the program if any errors were detected. Optionally specify allow=>'warning' to ignore warnings.

$self->info(Text...)

Print an informational about the object in a standard format. The object must have a fileline method.

$self->lineno()

The line number the entity was created on.

$self->unlink_if_error(filename)

Requests the given file be deleted if any errors are detected when the Logger object is destroyed. Used for temporary files.

$self->warn(Text...)

Print a warning about the object in a standard format. The object must have a fileline method.

Distribution

Verilog-Perl is part of the <https://www.veripool.org/> free Verilog EDA software tool suite. The latest version is available from CPAN and from <https://www.veripool.org/verilog-perl>.

Copyright 2000-2024 by Wilson Snyder. This package is free software; you can redistribute it and/or modify it under the terms of either the GNU Lesser General Public License Version 3 or the Perl Artistic License Version 2.0.

Releases

8 releases since Debian 6.0 (Squeeze); the text changed 7 times.

  1. 6.0
  2. 7
  3. 8
  4. 9
  5. 10
  6. 11
  7. 12
  8. 13

Authors

Wilson Snyder <[email protected]>

From libverilog-perl 3.482-2 in Debian 13 (Trixie). Parsed by carta from the page's man source.