diff options
author | Björn Gustavsson <[email protected]> | 2018-03-19 14:32:27 +0100 |
---|---|---|
committer | Björn Gustavsson <[email protected]> | 2018-03-19 14:32:27 +0100 |
commit | 6751506b67e3ba6f4ce9eacd040ea269fca643fd (patch) | |
tree | 4996ab1e071bb5c9dc4e7868b2222d29994b5b82 /lib/compiler/src/v3_kernel_pp.erl | |
parent | aa5a6ddb3ef4e3f36f49150e57fec2896e9314f2 (diff) | |
parent | 741e5b36684c80fead2283f57fabcf8b6e981af0 (diff) | |
download | otp-6751506b67e3ba6f4ce9eacd040ea269fca643fd.tar.gz otp-6751506b67e3ba6f4ce9eacd040ea269fca643fd.tar.bz2 otp-6751506b67e3ba6f4ce9eacd040ea269fca643fd.zip |
Merge branch 'bjorn/compiler/misc-fixes'
* bjorn/compiler/misc-fixes:
Teach beam_utils:replace_labels/4 to handle recv_{mark,set}
v3_kernel: Stop ensuring one return value in #k_try{}
v3_kernel_pp: Print return variables for #k_try{}
Diffstat (limited to 'lib/compiler/src/v3_kernel_pp.erl')
-rw-r--r-- | lib/compiler/src/v3_kernel_pp.erl | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/compiler/src/v3_kernel_pp.erl b/lib/compiler/src/v3_kernel_pp.erl index ac91039ae0..e9cbe81088 100644 --- a/lib/compiler/src/v3_kernel_pp.erl +++ b/lib/compiler/src/v3_kernel_pp.erl @@ -248,7 +248,7 @@ format_1(#k_put{arg=A,ret=Rs}, Ctxt) -> [format(A, Ctxt), format_ret(Rs, ctxt_bump_indent(Ctxt, 1)) ]; -format_1(#k_try{arg=A,vars=Vs,body=B,evars=Evs,handler=H}, Ctxt) -> +format_1(#k_try{arg=A,vars=Vs,body=B,evars=Evs,handler=H,ret=Rs}, Ctxt) -> Ctxt1 = ctxt_bump_indent(Ctxt, Ctxt#ctxt.body_indent), ["try", nl_indent(Ctxt1), @@ -264,7 +264,8 @@ format_1(#k_try{arg=A,vars=Vs,body=B,evars=Evs,handler=H}, Ctxt) -> nl_indent(Ctxt1), format(H, Ctxt1), nl_indent(Ctxt), - "end" + "end", + format_ret(Rs, Ctxt) ]; format_1(#k_try_enter{arg=A,vars=Vs,body=B,evars=Evs,handler=H}, Ctxt) -> Ctxt1 = ctxt_bump_indent(Ctxt, Ctxt#ctxt.body_indent), |