dtolnay/cxx

Raw identifiers in methods in extern "C++" block leads to wrong C++ code generation

Aberta

#1.324 aberto em 11 de mar. de 2024

 (0 comentário) (0 reação) (0 responsável)Rust (253 forks)batch import
help wanted

Métricas do repositório

Stars
 (4.472 estrelas)
Métricas de merge de PR
 (Métricas PR pendentes)

Description

For example

pub fn highlight(r#type: i32);

leads to

void ffi$cxxbridge1$highlight(::std::int32_t r#type) noexcept { ... }

I wish it could be unraw-ed if being a valid C++ identifier. Currently workaround with type_.

Guia do colaborador