# HG changeset patch # User jwe # Date 1028232488 0 # Node ID eb377885843df849c103ac9ee844a2fd31ffbcd2 # Parent 0a30852e0249d1f1befa553c3825cd607af6126d [project @ 2002-08-01 20:08:08 by jwe] diff --git a/scripts/ChangeLog b/scripts/ChangeLog --- a/scripts/ChangeLog +++ b/scripts/ChangeLog @@ -1,3 +1,11 @@ +2002-08-01 John W. Eaton + + * miscellaneous/popen2.m: Use F_SETFL and O_NONBLOCK, not + __F_SETFL__ and __O_NONBLOCK__. + + * image/saveimage.m: Use OCTAVE_VERSION, not __OCTAVE_VERSION__. + * miscellaneous/bug_report.m: Likewise. + 2002-07-25 John W. Eaton * general/mod.m: Use isreal (x), not any (any (imag (x))). diff --git a/scripts/image/saveimage.m b/scripts/image/saveimage.m --- a/scripts/image/saveimage.m +++ b/scripts/image/saveimage.m @@ -158,7 +158,7 @@ time_string = ctime (time ()); time_string = time_string (1:length (time_string)-1); tagline = sprintf ("# Created by Octave %s, %s", - __OCTAVE_VERSION__, time_string); + OCTAVE_VERSION, time_string); if (grey && bw) diff --git a/scripts/miscellaneous/bug_report.m b/scripts/miscellaneous/bug_report.m --- a/scripts/miscellaneous/bug_report.m +++ b/scripts/miscellaneous/bug_report.m @@ -50,7 +50,7 @@ endif endif - cmd = strcat ("octave-bug-", __OCTAVE_VERSION__); + cmd = strcat ("octave-bug-", OCTAVE_VERSION); if (length (subject) > 0) cmd = sprintf ("%s -s \"%s\"", cmd, subject); diff --git a/src/ChangeLog b/src/ChangeLog --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,15 @@ +2002-08-01 John W. Eaton + + * ov-cell.cc (octave_cell::print_raw): Print empty dimensions too. + (octave_cell::print_name_tag): Don't print new line if cell is empty. + + * octave.cc (intern_argv): Don't install __argv__. + + * defun-int.h (UNDERSCORIFY): Delete. + (DEFCONST_INTERNAL): Don't install double underscore versions of + constants since they aren't really needed. + (DEFCONSTX_INTERNAL): Likewise. + 2002-07-31 John W. Eaton * symtab.cc (symbol_table::clear (void)): Clear all records. diff --git a/src/defun-int.h b/src/defun-int.h --- a/src/defun-int.h +++ b/src/defun-int.h @@ -180,16 +180,11 @@ #define INSTALL_CONST(name, sname, defn, protect, doc) \ install_builtin_constant (name, octave_value (defn), protect, doc) -#define UNDERSCORIFY(name) \ - "__" name "__" - #define DEFCONST_INTERNAL(name, defn, doc) \ - INSTALL_CONST (#name, SBV_ ## name, defn, false, doc); \ - INSTALL_CONST (UNDERSCORIFY (#name), XSBV_ ## name, defn, true, doc) + INSTALL_CONST (#name, SBV_ ## name, defn, false, doc); #define DEFCONSTX_INTERNAL(name, sname, defn, doc) \ - INSTALL_CONST (name, sname, defn, false, doc); \ - INSTALL_CONST (UNDERSCORIFY (name), X ## sname, defn, true, doc) + INSTALL_CONST (name, sname, defn, false, doc); // How mapper functions are actually installed. diff --git a/src/octave.cc b/src/octave.cc --- a/src/octave.cc +++ b/src/octave.cc @@ -175,7 +175,6 @@ } bind_builtin_constant ("argv", octave_argv, true, true); - bind_builtin_constant ("__argv__", octave_argv, true, true); } static void diff --git a/src/ov-cell.cc b/src/ov-cell.cc --- a/src/ov-cell.cc +++ b/src/ov-cell.cc @@ -287,15 +287,30 @@ newline (os); } else - os << "{}"; + { + os << "{}"; + if (nr > 0 || nc > 0) + os << "(" << nr << "x" << nc << ")"; + os << "\n"; + } } bool octave_cell::print_name_tag (std::ostream& os, const std::string& name) const { indent (os); - os << name << " ="; - newline (os); + + int nr = rows (); + int nc = columns (); + + if (nr > 0 && nc > 0) + { + os << name << " ="; + newline (os); + } + else + os << name << " = "; + return false; }