Mercurial > hg > octave-lyh
changeset 17385:15e2ad6372f7
maint: Tweaks to remove compiler warnings.
* libgui/src/find-files-model.cc(rowCount, columnCount): Eliminate unused input
parameter p.
* libinterp/corefcn/octave-link.cc(F__octave_link_file_dialog__): Use signed int
in for loop index for comparison to octave_idx_type.
* libinterp/corefcn/txt-eng-ft.cc(ft_render::visit): Initialize all of
mbstate_t structure (not just first field) with memset() to 0.
* libinterp/parse-tree/oct-parse.in.yy(F__parse_file__): Remove unused nargout
parameter.
author | Rik <rik@octave.org> |
---|---|
date | Thu, 05 Sep 2013 10:34:09 -0700 |
parents | f0e3d3de5c22 |
children | 813523c2b581 |
files | libgui/src/find-files-model.cc libinterp/corefcn/octave-link.cc libinterp/corefcn/txt-eng-ft.cc libinterp/parse-tree/oct-parse.in.yy |
diffstat | 4 files changed, 14 insertions(+), 15 deletions(-) [+] |
line wrap: on
line diff
--- a/libgui/src/find-files-model.cc +++ b/libgui/src/find-files-model.cc @@ -111,13 +111,13 @@ } int -find_files_model::rowCount (const QModelIndex & p) const +find_files_model::rowCount (const QModelIndex &) const { return _files.size(); } int -find_files_model::columnCount (const QModelIndex & p) const +find_files_model::columnCount (const QModelIndex &) const { return _columnNames.size (); }
--- a/libinterp/corefcn/octave-link.cc +++ b/libinterp/corefcn/octave-link.cc @@ -255,7 +255,7 @@ std::list<std::string>::iterator it = items_lst.begin (); - for (unsigned int idx = 0; idx < nel; idx++) + for (int idx = 0; idx < nel; idx++) { items.xelem (idx) = *it; it++;
--- a/libinterp/corefcn/txt-eng-ft.cc +++ b/libinterp/corefcn/txt-eng-ft.cc @@ -42,8 +42,8 @@ #include "pr-output.h" #include "txt-eng-ft.h" -// FIXME -- maybe issue at most one warning per glyph/font/size/weight -// combination. +// FIXME: maybe issue at most one warning per glyph/font/size/weight +// combination. static void gripe_missing_glyph (FT_ULong c) @@ -62,10 +62,10 @@ } #ifdef _MSC_VER -// This is just a trick to avoid multiply symbols definition. +// This is just a trick to avoid multiple symbol definitions. // PermMatrix.h contains a dllexport'ed Array<octave_idx_type> -// that will make MSVC not to generate new instantiation and -// use the imported one. +// that will cause MSVC not to generate a new instantiation and +// use the imported one instead. #include "PermMatrix.h" #endif @@ -154,8 +154,7 @@ FT_Done_FreeType (library); #if defined (HAVE_FONTCONFIG) - // FIXME -- Skip the call to FcFini because it can trigger the - // assertion + // FIXME: Skip the call to FcFini because it can trigger the assertion // // octave: fccache.c:507: FcCacheFini: Assertion 'fcCacheChains[i] == ((void *)0)' failed. // @@ -225,7 +224,7 @@ FcDefaultSubstitute (pat); match = FcFontMatch (0, pat, &res); - // FIXME -- originally, this test also required that + // FIXME: originally, this test also required that // res != FcResultNoMatch. Is that really needed? if (match) { @@ -284,8 +283,7 @@ { if (face->generic.data) { - ft_key* pkey = - reinterpret_cast<ft_key*> (face->generic.data); + ft_key* pkey = reinterpret_cast<ft_key*> (face->generic.data); cache.erase (*pkey); delete pkey; @@ -634,7 +632,8 @@ std::string str = e.string_value (); size_t n = str.length (), curr = 0; - mbstate_t ps = { 0 }; + mbstate_t ps; + memset (&ps, 0, sizeof (ps)); // Initialize state to 0. wchar_t wc; while (n > 0)
--- a/libinterp/parse-tree/oct-parse.in.yy +++ b/libinterp/parse-tree/oct-parse.in.yy @@ -4436,7 +4436,7 @@ return retval; } -DEFUN (__parse_file__, args, nargout, +DEFUN (__parse_file__, args, , "-*- texinfo -*-\n\ @deftypefn {Built-in Function} {} __parse_file__ (@var{file}, @var{verbose})\n\ Undocumented internal function.\n\