Skip to content

bindgen-cli generates a mix of CRLF and LF file endings on Windows #2672

Closed
@ajantti

Description

@ajantti

It seems to use CRLF for the actual bindings, but the initial comment /* automatically generated by rust-bindgen 0.68.1 */ and the empty line after are with LF.

Input C/C++ Header

int foo;

Bindgen Invocation

$ bindgen test.h --output test.rs

Actual Results

I replaced the CR with ^M

/* automatically generated by rust-bindgen 0.68.1 */

extern "C" {^M
    pub static mut foo: ::std::os::raw::c_int;^M
}^M

Expected Results

I would expect it to either be all Dos or all Unix line endings.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions