# HG changeset patch # User John W. Eaton # Date 1247076413 14400 # Node ID bc2f0067e1407d24c5668563edb1a8da06838b0a # Parent a4672b478cef57fd76b94beb816d217fb55e49dd pt-assign.cc (maybe_warn_former_built_in_variable): improve message diff --git a/src/ChangeLog b/src/ChangeLog --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2009-07-08 John W. Eaton + + * pt-assign.cc (maybe_warn_former_built_in_variable): Improve message. + 2009-07-21 Jaroslav Hajek Version 3.2.2 released. diff --git a/src/pt-assign.cc b/src/pt-assign.cc --- a/src/pt-assign.cc +++ b/src/pt-assign.cc @@ -153,9 +153,13 @@ } if (vars.find (nm) != vars.end ()) - warning_with_id ("Octave:built-in-variable-assignment", - "%s is no longer a built-in variable; please read the NEWS file or type `news' for details", - nm.c_str ()); + { + const char *nm_c_str = nm.c_str (); + + warning_with_id ("Octave:built-in-variable-assignment", + "%s is now a function instead of a built-in variable. By assigning to %s, you have created a variable that hides the function %s. To remove the variable and restore the function, type \"clear %s\"", + nm_c_str, nm_c_str, nm_c_str, nm_c_str); + } } tree_simple_assignment::tree_simple_assignment