TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Problems of C, and how Zig addresses them

7 pointsby avesturaalmost 2 years ago

1 comment

sylwarealmost 2 years ago
Problems of C syntax:<p>- TLS in the syntax.<p>- Integer promotion.<p>- Implicit casts, missing explicit dynamic&#x2F;static casts. Implicit casts for number literals though (like rust), and for void* pointers too, very probably.<p>- Missing explicit compile-time constants.<p>- Too many loop keywords, one loop{} is enough.<p>- Enumerations, switch, and stuff like _Generic&#x2F;typeof, and more have to go.<p>- should have been only sized primitive types (u8&#x2F;s8...u64&#x2F;s64....f64, etc).<p>- and all the others I am forgetting right now.