InfoQ Homepage Generics Content on InfoQ
-
Swift 5.9 Brings a Macro System and C++ Interoperability
In addition to an expressive macro system and a limited form of C++ interoperability, Swift 5.9, now officially available, also introduces parameter packs, ownership-based memory management, and more.
-
.NET Hot Reload Adds Support for Modifying Generics
In the .NET 8 Preview 4 release, .NET Hot Reload implements support for modifying generic methods, reducing the number of changes that require restarting for the change to take effect.
-
Rust 1.65 Brings Generic Associated Types in a Step towards Higher-Kinded Types
The latest release of Rust introduces a powerful new language feature, called generic associated types, that allows developers to specify generics on associated types in traits. Other notable new features include the let-else statement, and support for breaking out of labeled blocks.
-
Swift 5.7 Brings New Generics Implementation and Reference Counting Improvements
Announced at WWDC 2022, Swift 5.7 is now officially available. It includes major improvements to the compiler internals, and many syntax and standard library additions, including String regex, concurrency updates, and more.
-
Go 1.19 Improves Generics Performance and Refines its Memory Model
Go 1.19 focuses on improving the implementation of the toolchain, runtime, and libraries, especially for generics performance, the language memory model, and garbage collection.
-
On Go's Generics Implementation and Performance
On the heels of Go generics becoming stable in Go 1.18, PlanetScale performance engineer Vicent Martà dissected how they work and highlighted some performance limitations of their actual implementation. He also provided a few handy suggestions about their usage.
-
Go 1.18 Stabilizes Generics, Fuzzing, Multi-Module Support, and Improves Performance
The Go team has announced the release of Go 1.18, which brings support for generics, fuzzing, workspaces, and performance improvements.
-
Go Generics Debut in Go 1.18 Beta 1
The latest beta release of Go, Go 1.18 beta 1, finally introduces support for generics programming using parametrized types, a long-awaited and highly-requested feature. Additionally, it also adds support for test fuzzing, a technique used to find inputs then uncover incorrect behaviour in a program.
-
Rust 1.51 Stabilizes Const Generics MVP, Improves Cargo and Compile Times
Rust 1.51 brings to stable a minimum value proposition for const generics, which enable parametrizing types by constant values, for example integers, as opposed to types or lifetimes. The new Rust release also includes improvements to Cargo with a new feature resolver, and faster compile times on macOS.
-
Generics Enter Go Change Proposal Process
Generics, one of the features more frequently requested by Go developers, are making their way into the language based on a draft design that has been evolving for the last couple of years and is now entering the language change proposal process.
-
Go Contracts Will Enable Generic Programming
A new draft to add support for generic programming to Go is centered around the concept of contracts, which are used to constrain type parameters to types and functions. The draft also introduces type inference to simplify the use of generic types and functions by allowing developers to omit types in many cases.
-
TypeScript 2.3 Adds Generic Default Arguments, Async Iterators Support, and More
TypeScript 2.3 extends the language syntax by adding support for declaring defaults for generic type parameters and for async generators and iterators. It also aims to improve integration with existing JavaScript code with a new compile option and introduces official support for language server plugins.
-
New JEP Would Simplify Java Type Variance
A new JEP Candidate proposes to facilitate the handling of type variance in Java. The new proposal, potentially targeting Java 10, would add a means for specifying the default variance in the definition of generic types, different to the current style of indicating it through wildcards at instantiation. This proposal is not a replacement for wildcards, but rather a way to reduce the need for them.
-
Java Enums to Be Enhanced with Sharper Type Support
Java enums will be enhanced with generics support and with the ability to add methods to individual items, a new JEP shows. Since both features can be delivered with the same code change, they are bundled together in the same JEP. The change only affects the Java compiler, and therefore no runtime changes are needed. Although there is no target version, Java 10 seems likely.
-
Richard Warburton and Raoul-Gabriel Urma Review the History of Generics in Java at Devoxx UK
Richard and Raoul, who provide in person training courses on Java 8, offered a joint presentation at Devoxx UK 2015 where they discussed the origins and motivations for Generics in Java, some of the less known current features, and a glimpse of what might be coming up in Java 10. The presentation was split into three distinctive sections: past, present and future of Generics.