Mercurial > hg > octave-avbm
diff src/oct-parse.yy @ 13125:34a49d076155
Show row/column for anonymous functions in the profiler
* oct-parse.yy (make_anon_fcn_handle): Initialize l and c to current position.
* pt-fcn-handle.h: Keep track of filename.
* pt-fcn-handle.cc: Ditto.
author | Daniel Kraft <d@domob.eu> |
---|---|
date | Fri, 09 Sep 2011 20:14:53 +0200 (2011-09-09) |
parents | 50db905c3cf1 |
children | 1bfca2bbea8b |
line wrap: on
line diff
--- a/src/oct-parse.yy +++ b/src/oct-parse.yy @@ -2071,9 +2071,8 @@ make_anon_fcn_handle (tree_parameter_list *param_list, tree_statement *stmt) { // FIXME -- need to get these from the location of the @ symbol. - - int l = -1; - int c = -1; + int l = input_line_number; + int c = current_input_column; tree_parameter_list *ret_list = 0; @@ -2094,6 +2093,9 @@ tree_anon_fcn_handle *retval = new tree_anon_fcn_handle (param_list, ret_list, body, fcn_scope, l, c); + // FIXME: Stash the filename. This does not work and produces + // errors when executed. + //retval->stash_file_name (curr_fcn_file_name); return retval; }