HackerTube

Introducing a Memory-Safe Successor Language in Large C++ Code Bases - John McCall - CppNow 2023

CppNow3 HN recommenders · recommended in 3 months, 2023–2025
YouTube
talk · advanced · 2023–2025 on HN

John McCall of Apple's Swift team presents at CppNow 2023 on introducing a memory-safe successor language into large C++ code bases. He argues incremental improvement of C++ hits hard limits and explains Swift's C++ interoperability for gradual migration.

Used as the primary source for Apple's stated plan to make Swift its successor to C++ and for how interop supports gradual transition.

12 comments from Hacker News

@glhaynes2024-06 · in “Swift Static Linux SDK”

I'm not a (direct) user of the C++ interop, but everything I've heard about it has been quite positive. A few hopefully relevant resources, first a couple of videos: - "Introducing a Memory-Safe Successor Language in Large C++ Code Bases" (John McCall; CppNow 2023) ▶ this video - "Swift as C++ Successor in FoundationDB" (Konrad Malawski; Strange Loop 2023) link And then a series of blog posts by Doug Gregor: - "Swift for C++ Practitioners" link And finally: - "Mixing Swift and C++" (Swift.org) link

Recommends View on HN
@mannuch2023-12 · in “Memory safety is necessary, not sufficient”

I wonder what the author thinks about Swift’s new C++ interop story? Since the Swift compiler includes Clang, and can thus compile both your C++ and Swift into LLVM IR, without the need for an FFI later between the two, couldn’t this be the “Typescript for C++” that the author points out a space for? The Swift folks are very much thinking about Swift as a C++ successor that can be incrementally migrated to so I’m a bit surprised the author didn’t discuss it further — especially given Swift’s spiritual similarities to Rust. There’s a couple great talks on this by folks on the Swift team. John McCall at CppNow ▶ this video Konrad Malawski at StrangeLoop 2023 link

Recommends View on HN
@pjmlp2023-09 · in “Show HN: C-ocoa, Write iOS/macOS apps in any language, with a generated C API”

Java also compiles to native code on Android. Try to write an iOS application using only C and C++, instead of either Objective-C or Swift. "Swift was designed from the outset to be safer than C-based languages, and eliminates entire classes of unsafe code" -- link "Swift is a successor to the C, C++, and Objective-C languages. It includes low-level primitives such as types, flow control, and operators. It also provides object-oriented features such as classes, protocols, and generics, giving Cocoa and Cocoa Touch developers the performance and power they demand." -- link Some of the information related their Safe C dialect, link "2023 EuroLLVM - Keynote: “-fbounds-safety”: Enforcing bounds safety for production C code" link Finaly a recent gem from CppNow 2023, "Introducing a Memory-Safe Successor Language in Large C++ Code Bases" ▶ this video

Recommends View on HN
@pjmlp2023-09 · in “Interoperability: Swift’s Super Power”

On the same note, watch Apple's talk at CppCon 2023, "Introducing a Memory-Safe Successor Language in Large C++ Code Bases" ▶ this video

Recommends View on HN
@pjmlp2025-04 · in “Apple’s Darwin OS and XNU Kernel Deep Dive”

Yes, Apple themselves, apparently folks wanting Apple to use Rust don't read Apple's documentation or watch talks done by Apple compiler developers. > Swift was designed from the outset to be safer than C-based languages, and eliminates entire classes of unsafe code. -- link > Swift is a successor to the C, C++, and Objective-C languages. It includes low-level primitives such as types, flow control, and operators. It also provides object-oriented features such as classes, protocols, and generics. -- link "Introducing a Memory-Safe Successor Language in Large C++ Code Bases" ▶ this video "So we feel pretty strongly, obviously at Apple our sucessor language is Swift and I am here to talk about features of Swift, both to try to sell you on to it, but also to talk about the things we think are pretty necessary and the ways in which a programming language can support, you know, clear code, safer and more correct code." "Like I said before, Apple has always intended for Swift to be a sucessor language for all of our predecessors, from the top to the bottom of our stack, accessible to novices, powerful enough for experts, it is real a tall order. From ▶ this video to ▶ this video "Swift as C++ Successor in FoundationDB" link