Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> Swift 6.3 introduces the @c attribute, which lets you expose Swift functions and enums to C code in your project. Annotating a function or enum with @c prompts Swift to include a corresponding declaration in the generated C header that you can include in your C/C++ files

Why did this take so long to be added? Such strange priorities. Adding an entire C++ compiler for C++ interoperability before adding... C exports. Bizarre.



They had it earlier, as an underscored attribute.


it's been there for a while as an experimental feature. I used it in a project


You already had ObjC export so it was arguably low priority given the crossover




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: