OpenCores
URL https://opencores.org/ocsvn/socgen/socgen/trunk

Subversion Repositories socgen

[/] [socgen/] [trunk/] [tools/] [verilog/] [peval] - Blame information for rev 125

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 125 jt_eaton
################################################## ############
2
#!perl
3
 
4
use strict;
5
 
6
$| = 1;
7
 
8
while (1) {
9
print "Please enter your expression (or 'exit' to exit): ";
10
chomp(my $cmd = <>);
11
exit if ($cmd =~ /^\s*exit\s*$/);
12
 
13
my $result = eval "$cmd";
14
print "Result = $result\n\n";
15
}
16
################################################## ############

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.