You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I ran rustfmt 0.99.2-nightly (5c9a2b6 2018-08-07) through my indent_style = "Visual" codebase and it resulted in this weird formatting in a couple of places:
let pro_que = context.and_then(|ctx| {
ocl::ProQue::builder().context(ctx).prog_bldr(ocl::Program::builder().src(include_str!("../../cl_src/color_conversion.cl")).src(include_str!("../../cl_src/sampling.cl"))).build().chain_err(|| "error building ocl::ProQue")}).map(|pro_que| Box::into_raw(Box::new(pro_que))).map_err(report_opencl_error).ok();
More minimal reproduction case (the only option required is indent_style = "Visual"):
Actually, it seems that sometimes rustfmt just gives up and preserves the whatever formatting the closure had originally. Joining all of these lines into one and running rustfmt results in this (without any errors or warnings in the output):
I ran
rustfmt 0.99.2-nightly (5c9a2b6 2018-08-07)
through myindent_style = "Visual"
codebase and it resulted in this weird formatting in a couple of places:More minimal reproduction case (the only option required is
indent_style = "Visual"
):Actually, it seems that sometimes rustfmt just gives up and preserves the whatever formatting the closure had originally. Joining all of these lines into one and running rustfmt results in this (without any errors or warnings in the output):
Default settings (
indent_style = "Block"
) handles all of this correctly (with Block formatting obviously).I expect rustfmt to at least format things properly even if overflowing
max_width
rather than just do nothing in this case.The text was updated successfully, but these errors were encountered: