diff src/oct-parse.yy @ 14507:3f21c0c34b8f

check for function/file name mismatch when parsing class methods * oct-parse.yy (frob_function): Also check for and repair function name/file name mismatch when parsing class methods. * test/bug-36025: New test directory. * test/Makefile.am: Include bug-36025/module.mk.
author John W. Eaton <jwe@octave.org>
date Wed, 28 Mar 2012 23:21:44 -0400
parents 97883071e8e4
children e0d66b8b0c63
line wrap: on
line diff
--- a/src/oct-parse.yy	Wed Mar 28 12:59:46 2012 -0400
+++ b/src/oct-parse.yy	Wed Mar 28 23:21:44 2012 -0400
@@ -2823,8 +2823,7 @@
   // file.  Matlab doesn't provide a diagnostic (it ignores the stated
   // name).
   if (! autoloading && reading_fcn_file
-      && (current_function_depth == 1
-          && ! (parsing_subfunctions || lexer_flags.parsing_class_method)))
+      && current_function_depth == 1 && ! parsing_subfunctions)
   {
     // FIXME -- should curr_fcn_file_name already be
     // preprocessed when we get here?  It seems to only be a