From ce5e42bb77e7c7bac65654e4b7d794b222a236e5 Mon Sep 17 00:00:00 2001 From: Ger van Diepen Date: Thu, 31 Jan 2019 12:24:14 +0100 Subject: [PATCH] Fixed doxygen warnings --- build-tools/doxygen_pp | 27 ++++++++++++++++++--------- casa/Arrays/Array.h | 6 +++--- casa/Containers/RecordDesc.h | 2 +- casa/Containers/RecordDescRep.h | 2 +- doxygen.cfg | 18 ++++-------------- ms/MSOper/MSConcat.h | 32 ++++++++------------------------ msfits/MSFits/MSFitsOutput.h | 16 ++++------------ scimath/Mathematics/AutoDiff.h | 4 +--- tables/LogTables/LoggerHolder.h | 2 +- 9 files changed, 41 insertions(+), 68 deletions(-) diff --git a/build-tools/doxygen_pp b/build-tools/doxygen_pp index 2d9896293c9..4ae9de29529 100755 --- a/build-tools/doxygen_pp +++ b/build-tools/doxygen_pp @@ -135,11 +135,11 @@ sub handleLinkto if ($linkstr =~ m||i) { # A link to a class. $linkstr =~ s|| \\link casacore::$1 |i; - $endlink = " \\endlink"; + $endlink = "\\endlink"; } elsif ($linkstr =~ m%%i) { # A link to a module. $linkstr =~ s%% \\ref $1_module_anchor "%i; - $endlink = "\""; + $endlink = '"'; } else { # A link to an anchor in a group or file. if ($linkstr =~ m%%i) { @@ -159,7 +159,7 @@ sub handleLinkto my $classnm = $1; my $funcnm = $2; $linkstr =~ s%% \\link ${classnm}::$funcnm() %i; - $endlink = ' \\endlink'; + $endlink = '\\endlink'; } elsif ($linkstr =~ m%%) { # A link to a class or module anchor. my $grpnm = $2; @@ -233,6 +233,7 @@ sub change_comment_style $extraline = ""; $grouplevel = 0; $namedgrouplevel = 0; + $nexamples = 0; $code = 0; # no block found $link = 0; # no block found $linkfr = 0; # no found @@ -365,13 +366,14 @@ sub change_comment_style # Replace it by a doxygen \anchor tag and an tag. # Prepend the doxygen name with the header name. # The latter one is used for internal references. - if ( $comment =~ m||i ) { + if ( $comment =~ m||i ) { my $nm = $1; + my $rem = $2; my $dnm = $nm; $dnm =~ s|\s*['".]\s*||g; $dnm =~ s|\s+|_|g; $dnm =~ s|:|_|g; - $comment =~ s|| \\anchor $dnm |i; + $comment =~ s|| \\anchor $dnm |i; } $comment =~ s|||ig; @@ -428,7 +430,10 @@ sub change_comment_style $comment =~ s|||ig; $comment =~ s||

Synopsis

|ig; $comment =~ s|
||ig; - $comment =~ s||

Example

\\anchor ${hdrnm}_example|ig; + if ( $comment =~ m||i ) { + $nexamples += 1; + $comment =~ s||

Example

\\anchor ${hdrnm}_example${nexamples}|ig; + } $comment =~ s|
||ig; $comment =~ s||

Etymology

|ig; $comment =~ s|
||ig; @@ -641,9 +646,8 @@ sub change_comment_style $line = "//$comment\n"; $newstate = $NON_COMMENT_BLOCK; } - } - # A blank line does not change anything. - elsif ($line =~ /^\s*$/) { + } elsif ($line =~ /^\s*$/) { + # A blank line does not change anything. $newstate = $state; if ($nadded > 0) { $nadded -= 1; @@ -653,6 +657,11 @@ sub change_comment_style } else { $keephash = 0; } + # Remove stray spaces left before ) or after ( . and ,. + $comment =~ s/\(\s+/(/g; + $comment =~ s/\s+\)/)/g; + $comment =~ s/\s+\././g; + $comment =~ s/\s+,/,/g; # Act depending on new and old state. if ($skip == 0) { diff --git a/casa/Arrays/Array.h b/casa/Arrays/Array.h index 33eb45805af..9f59b1b8ef3 100644 --- a/casa/Arrays/Array.h +++ b/casa/Arrays/Array.h @@ -220,7 +220,7 @@ template class Array : public ArrayBase // Otherwise, allocator is ignored. // It is strongly recommended to allocate and initialize storage with DefaultAllocator // rather than new[] or NewDelAllocator because new[] can't decouple allocation and initialization. - // DefaultAllocator::type is a subclass of std::allocator. You can allocate storage via + // DefaultAllocator is a subclass of std::allocator. You can allocate storage via // the allocator as below. // // FILE *fp = ...; @@ -779,7 +779,7 @@ template class Array : public ArrayBase class ConstIteratorSTL: public BaseIteratorSTL { public: - // + // typedef T value_type; typedef const value_type* pointer; typedef const value_type& reference; @@ -842,7 +842,7 @@ template class Array : public ArrayBase // If the array is contiguous, it is possible to use the // cbegin and cend functions which are // about 10% faster. - // + // // STL-style typedefs. // typedef T value_type; diff --git a/casa/Containers/RecordDesc.h b/casa/Containers/RecordDesc.h index b8bdfd57ddd..b122c20bb5a 100644 --- a/casa/Containers/RecordDesc.h +++ b/casa/Containers/RecordDesc.h @@ -85,7 +85,7 @@ class AipsIO; // // // See the example in the description of the -// Record class. +// Record class. // // // diff --git a/casa/Containers/RecordDescRep.h b/casa/Containers/RecordDescRep.h index 4a0fb990688..f0cc6f6a6ac 100644 --- a/casa/Containers/RecordDescRep.h +++ b/casa/Containers/RecordDescRep.h @@ -73,7 +73,7 @@ class AipsIO; // // See the example in the description of the -// Record class. +// Record class. // // diff --git a/doxygen.cfg b/doxygen.cfg index 6680723c855..08e545139e1 100644 --- a/doxygen.cfg +++ b/doxygen.cfg @@ -382,7 +382,8 @@ TYPEDEF_HIDES_STRUCT = NO # the optimal cache size from a speed point of view. # Minimum value: 0, maximum value: 9, default value: 0. -LOOKUP_CACHE_SIZE = 0 +# Set to 1 based on feedback from a doxygen run +LOOKUP_CACHE_SIZE = 1 #--------------------------------------------------------------------------- # Build related configuration options @@ -804,7 +805,8 @@ EXCLUDE_PATTERNS = */build_* \ */test/* \ */include/* \ */fortran/* \ - */.git/* + */.git/* \ + */*sav*/* # The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names # (namespaces, classes, functions, etc.) that should be excluded from the @@ -1799,18 +1801,6 @@ GENERATE_XML = NO XML_OUTPUT = xml -# The XML_SCHEMA tag can be used to specify a XML schema, which can be used by a -# validating XML parser to check the syntax of the XML files. -# This tag requires that the tag GENERATE_XML is set to YES. - -XML_SCHEMA = - -# The XML_DTD tag can be used to specify a XML DTD, which can be used by a -# validating XML parser to check the syntax of the XML files. -# This tag requires that the tag GENERATE_XML is set to YES. - -XML_DTD = - # If the XML_PROGRAMLISTING tag is set to YES doxygen will dump the program # listings (including syntax highlighting and cross-referencing information) to # the XML output. Note that enabling this will significantly increase the size diff --git a/ms/MSOper/MSConcat.h b/ms/MSOper/MSConcat.h index e2855287e99..dd5181c656c 100644 --- a/ms/MSOper/MSConcat.h +++ b/ms/MSOper/MSConcat.h @@ -57,9 +57,6 @@ template class Block; // // -//
  • SomeClass -//
  • SomeOtherClass -//
  • some concept // // // @@ -74,20 +71,7 @@ template class Block; // // // -// -//
  • -//
  • -// -// -// -//
  • -//
  • -// -// // -//
  • add this feature -//
  • fix this bug -//
  • start discussion of this possible extension // class MSConcat: public MSColumns @@ -100,16 +84,16 @@ class MSConcat: public MSColumns const String& obsidAndScanTableName=""); void concatenate(const MeasurementSet& otherMS, - const uInt handling=0, // 0 (default): complete concat of all tables - // 1 : don't concatenate the MAIN table - // 2 : don't concatenate the POINTING table - // 3 : neither concat MAIN nor POINTING table - const String& destMSName=""); // support for virtual concat + const uInt handling=0, //# 0 (default): complete concat of all tables + //# 1 : don't concatenate the MAIN table + //# 2 : don't concatenate the POINTING table + //# 3 : neither concat MAIN nor POINTING table + const String& destMSName=""); //# support for virtual concat void setTolerance(Quantum& freqTol, Quantum& dirTol); void setWeightScale(const Float weightScale); - void setRespectForFieldName(const Bool respectFieldName); // If True, fields of same direction are not merged - // if their name is different + void setRespectForFieldName(const Bool respectFieldName); //# If True, fields of same direction are not merged + //# if their name is different private: MSConcat(); @@ -126,7 +110,7 @@ class MSConcat: public MSColumns Bool copySysCal(const MSSysCal& otherSysCal, const Block& newAndIndices); Bool copyWeather(const MSWeather& otherWeather, const Block& newAndIndices); Int copyObservation(const MSObservation& otherObs, const Bool remRedunObsId=True); - // by default remove redundant observation table rows + //# by default remove redundant observation table rows Block copyAntennaAndFeed(const MSAntenna& otherAnt, const MSFeed& otherFeed); Block copyState(const MSState& otherState); diff --git a/msfits/MSFits/MSFitsOutput.h b/msfits/MSFits/MSFitsOutput.h index b0715a9697b..94c6298cebd 100644 --- a/msfits/MSFits/MSFitsOutput.h +++ b/msfits/MSFits/MSFitsOutput.h @@ -58,10 +58,10 @@ class MSFitsOutput { const String& column ); - // @param startchan 1st channel + // @param startChan 1st channel // @param nchan # of channels - // @param stepchan # of channels to stride by - // @param avgchan average every N channels + // @param stepChan # of channels to stride by + // @param avgChan average every N channels void setChannelInfo( Int startChan, Int nchan, Int stepChan, Int avgChan ); @@ -114,6 +114,7 @@ class MSFitsOutput { // as needed to fit the IF structure. Does not yet // support spws with different shapes. // @param avgchan average every N channels + // @param fieldNumber field number // @param overwrite overwrite existing file? static Bool writeFitsFile( const String& fitsfile, const MeasurementSet& ms, @@ -141,21 +142,12 @@ class MSFitsOutput { // @param refFreq // @param chanbw // @param outFITSFile - // @param rawms - // @param column data column to write // @param spwidMap spwidMap[inp_spw] = output_spw, if inp_spw is selected // -1 otherwise. // @param nrspw # of selected spws. - // @param startchan First channel - // @param nchan # of channels - // @param stepchan channel stride // @param fieldidMap fieldidMap[inp_fld] = output_fld, if inp_fld is selected // -1 otherwise. // @param asMultiSource If true, write a multisource UVFITS file. - // @param combineSpw If true, export the spectral window(s) as IF(s). - // @param padWithFlags If true && combineSpw==true, pad the spws with - // flags as necessary to fit the IF structure. - // @param avgchan average every N channels FitsOutput* _writeMain( Int& refPixelFreq, Double& refFreq, Double& chanbw, const String& outFITSFile, diff --git a/scimath/Mathematics/AutoDiff.h b/scimath/Mathematics/AutoDiff.h index 7a53e73f4a6..43c092ac6d5 100644 --- a/scimath/Mathematics/AutoDiff.h +++ b/scimath/Mathematics/AutoDiff.h @@ -165,9 +165,7 @@ namespace casacore { //# NAMESPACE CASACORE - BEGIN // // All operators and functions are declared in // AutoDiffMath. The output operator in -// AutoDiffIO. The actual structure of the -// data block used by AutoDiff is described in -// AutoDiffRep. +// AutoDiffIO. // // // diff --git a/tables/LogTables/LoggerHolder.h b/tables/LogTables/LoggerHolder.h index 2e40da8dc83..50c624fa5d9 100644 --- a/tables/LogTables/LoggerHolder.h +++ b/tables/LogTables/LoggerHolder.h @@ -317,7 +317,7 @@ class LoggerHolderRep // cout << iter.message() << endl; // } // - // + // // STL-style typedefs. typedef LoggerHolderIterator const_iterator; // Get the begin and end iterator object.