Files
hdf5/bin/checkposix
Robb Matzke b227b38853 [svn-r204] Changes since 19980129
----------------------

./RELEASE
        Added Library functions that I missed the first time.

./html/Datasets.html
        Added an example for Elena's question about how to read a
        single member of a compound data type so it becomes an array
        of that member in memory.

./src/H5Pprivate.h
        Fixed the prototype for H5P_get_hyperslab() to match the
        definition.

./src/H5Psimp.c
        Oops, added the kludge back in for the offset argument, which
        is still an `intn' instead of a `size_t'.

./src/H5.c
./src/H5public.h
./src/H5F.c
./src/H5T.c
./src/H5Tpublic.h
        Changed H5init() to H5open() and added an H5close() to fit our
        create/open/close paradigm.  The H5open() happens
        automatically on the first call to the HDF5 library.  The
        H5close() happens automatically on exit() (unless the app
        turns off that feature). H5close() closes all datasets and
        files and releases all resources used by the library.

./test/dsets.c
        Added calls to H5open() and H5close() to test them.

./test/dtypes.c
        Removed call to H5init() since we no longer need it there.

./src/H5Fstdio.c
        Changed the PABLO_MASK to the right value.  Thanks Kim.
1998-01-30 14:25:44 -05:00

62 lines
1.6 KiB
Perl
Executable File

#!/usr/local/bin/perl -w
require 5.003;
# Copyright (C) 1997 National Center for Supercomputing Applications.
# All rights reserved.
#
# Robb Matzke, matzke@llnl.gov
# 30 Aug 1997
#
# Purpose: Given the names of C source files this script will print the
# file name, line number, and function name of any function that
# doesn't begin with the letter `h' or `H' as stipulated by the
# HDF5 programming style guide.
#
# Emacs users can run this script as the compile command and
# use `next-error' (usually bound to M-`) to find each name
# violation.
while (<>) {
# Get rid of comments by removing the inside part.
s|/\*.*?\*/||g;
if ($in_comment) {
if (/\*\//) {
s|.*?\*/||;
$in_comment = 0;
} else {
$_="\n";
}
} elsif (m|/\*|) {
s|/\*.*||;
$in_comment = 1;
}
# Get rid of string constants if they begin and end on this line.
s/([\'\"])([^\1]|\\\1)*?\1/$1$1/g;
# Now find all function calls on this line
while (($name)=/\b([a-gi-z_A-GI-Z]\w*)\s*\(/) {
$_ = $';
# Ignore C statements that look sort of like function
# calls.
next if $name =~ /^(if|for|return|sizeof|switch|while|void)$/;
# These are really HDF5 functions/macros even though they don't
# start with `h' or `H'.
next if $name =~ /^FUNC_(ENTER|LEAVE)(_INIT)?$/;
next if $name =~ /^U?INT(8|16|32|64)(ENCODE|DECODE)$/;
next if $name =~ /^(MIN|MAX3?|NELMTS|BOUND|CONSTR)$/;
# These functions/macros are exempt.
next if $name =~ /^(assert|main|[fs]?printf)$/;
print "$ARGV:$.: $name\n";
}
} continue {
close ARGV if eof;
}