Menu

#GenEricS

14 posts

Feed·
14 of 14 posts
"Generic Methods in Go 1.27"
🖼️
0Read More

"Generic Methods in Go 1.27"

Hacker News·2 months ago
#G5g5nlKg

"An explanation of generic methods in Go, covering method-level type parameters and why dynamic dispatch prevents them from being declared inside interfaces."

15s
Generics in CrabPascal: TList and TDictionary (v2.15.0) | Generics no CrabPascal: TList e TDictionary (v2.15.0)
🖼️
0Read More

Generics in CrabPascal: TList and TDictionary (v2.15.0) | Generics no CrabPascal: TList e TDictionary (v2.15.0)

DEV Community·CrabPascal·5 months ago
#iQwCnUG5
#dev#portugus#string#tdictionary#generics

Bilingual post · Post bilíngue Jump to: English · Português English {#english} ...

15s
Java Generics, Type Erasure, and a conceptual idea: reified generics as a first-class citizen?
🖼️
0Read More

Java Generics, Type Erasure, and a conceptual idea: reified generics as a first-class citizen?

DEV Community·Luis Vasquez·6 months ago
#xrBy5Wfi
#java#jdk#generics#programming#type

From Dev.to - java: Java Generics, Type Erasure, and a conceptual idea: reified generics as a first-class citizen?

15s
`infer` in Conditional Types: 5 Recipes That Aren't in the Handbook
🖼️
0Read More

`infer` in Conditional Types: 5 Recipes That Aren't in the Handbook

DEV Community·Gabriel Anhaia·6 months ago
#oMx0MsXM
#recipe#typescript#types#generics#type

Five infer recipes past the handbook: tuple last/head/tail, URL param extraction, overload-aware constructors, promise-chain resolution.

15s
Opaque Types Without `unique symbol`: A Lighter Branded-Types Pattern
🖼️
0Read More

Opaque Types Without `unique symbol`: A Lighter Branded-Types Pattern

DEV Community·Gabriel Anhaia·6 months ago
#eVCGe9la
#typescript#types#generics#brand#string

Branded types without unique symbol — phantom-string-literal brands compose better, with one collision trade-off. Pattern + use cases.

15s
The maps Stdlib in Go 1.21+: 8 Functions That Replace Half Your Map Helpers
🖼️
0Read More

The maps Stdlib in Go 1.21+: 8 Functions That Replace Half Your Map Helpers

DEV Community·Gabriel Anhaia·6 months ago
#DbH9IB7c
#go#stdlib#generics#backend#maps

Go's maps stdlib package: 8 functions that delete handwritten helpers. Keys/Values/Clone/Copy/DeleteFunc/Equal + the iter.Seq trap.

15s
Generic-Heavy APIs Hurt Compile Times. Here Is How to Measure It
🖼️
0Read More

Generic-Heavy APIs Hurt Compile Times. Here Is How to Measure It

DEV Community·Gabriel Anhaia·6 months ago
#8NBNaJjq
#pattern#go#generics#benchmark#generic

Generics in Go look free at the call site. The compiler bills you for them later in time go build and binary size. Three patterns that cut the bill.

15s
Stop Using `interface{}` Even in Your Generic Code
🖼️
0Read More

Stop Using `interface{}` Even in Your Generic Code

DEV Community·Gabriel Anhaia·6 months ago
#Fj5LxtC0
#pattern#go#generics#programming#type

You shipped generics in 2022 and still write any inside them. Three patterns where the escape hatch is hiding, and what the constraint should be.

15s
Generic Constraints in Go: comparable, ~int, and the Trap of Underlying Types
🖼️
0Read More

Generic Constraints in Go: comparable, ~int, and the Trap of Underlying Types

DEV Community·Gabriel Anhaia·6 months ago
#870NSbjV
#go#generics#programming#type#constraint

any, comparable, cmp.Ordered, and the tilde. Four type-set constructs that decide whether your generic Go code compiles, and what it forgets.

15s
**Rust Const Generics: Write Generic Code Once, Get Hand-Optimized Performance Every Time**
🖼️
0Read More

**Rust Const Generics: Write Generic Code Once, Get Hand-Optimized Performance Every Time**

DEV Community·Nithin Bharadwaj·6 months ago
#XeZ9XCJM

Discover how Rust's const generics eliminate runtime overhead and type-unsafe code. Learn to write faster, safer generic functions with compile-time array sizes. Read more.

15s
We Killed `interface{}` From a Go Codebase. Here's What Replaced It
🖼️
0Read More

We Killed `interface{}` From a Go Codebase. Here's What Replaced It

DEV Community·Gabriel Anhaia·6 months ago
#gADqVoUS
#bucket#go#generics#refactoring#type

200+ uses of any in one Go codebase, three patterns under the hood. Generics, small consumer-side interfaces, and typed structs replaced almost all of it.

15s
Go Generics in 2026: What Finally Works and What Still Doesn't
🖼️
0Read More

Go Generics in 2026: What Finally Works and What Still Doesn't

DEV Community·Gabriel Anhaia·6 months ago
#DUx1LWso
#go#programming#generics#func#type

Four years in, Go generics have a clear shipping list. Type inference, comparable, Result/Option. And a list of things that still don't work.

15s