Mercurial > hg > octave-lyh
diff src/pt-except.cc @ 5861:2a6cb4ed8f1e
[project @ 2006-06-16 05:09:41 by jwe]
author | jwe |
---|---|
date | Fri, 16 Jun 2006 05:09:42 +0000 |
parents | ace8d8d26933 |
children | 93c65f2a5668 |
line wrap: on
line diff
--- a/src/pt-except.cc +++ b/src/pt-except.cc @@ -126,6 +126,17 @@ } } +tree_command * +tree_try_catch_command::dup (symbol_table *sym_tab) +{ + return new tree_try_catch_command (try_code ? try_code->dup (sym_tab) : 0, + catch_code ? catch_code->dup (sym_tab) : 0, + lead_comm ? lead_comm->dup () : 0, + mid_comm ? mid_comm->dup () : 0, + trail_comm ? trail_comm->dup () : 0, + line (), column ()); +} + void tree_try_catch_command::accept (tree_walker& tw) { @@ -231,6 +242,18 @@ unwind_protect::run (); } +tree_command * +tree_unwind_protect_command::dup (symbol_table *sym_tab) +{ + return new tree_unwind_protect_command + (unwind_protect_code ? unwind_protect_code->dup (sym_tab) : 0, + cleanup_code ? cleanup_code->dup (sym_tab) : 0, + lead_comm ? lead_comm->dup () : 0, + mid_comm ? mid_comm->dup () : 0, + trail_comm ? trail_comm->dup () : 0, + line (), column ()); +} + void tree_unwind_protect_command::accept (tree_walker& tw) {