~/talk

Engineering & Technical Highlight: Let's Do Some Crimes. The wonders of abusing C# generics.

links:none on file
slides:none on file

Generics are used to build zero-allocation utilities: a generic static class with a static constructor creates a precomputed enum info lookup table with safe To/From UInt64 casting, name lookup and HasName; extension methods and unsafe casts let enums convert without boxing. Iteration utilities take struct enumerators and use ref structs and a Begin helper to return a Zinc LINQ replacement that composes where/select without closures by passing invariants (value tuples) and avoids heap allocations. Code is road-tested in shipped games and published as Unity UPM packages.

AI-written summary · about

  1. 0:00Introduction
  2. 7:48Enumerator boxing with generics
  3. 13:44Enum APIs with generics
  4. 27:03LINQ vs zero-allocation queries
  5. 44:31Q&A
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.