hn.today

C3 0.8.6:Library fetching,30% smaller safe-mode binaries,and stricter type rules

c3-lang.org5 points0 comments
Screenshot of C3 0.8.6:Library fetching,30% smaller safe-mode binaries,and stricter type rules

C3 0.8.6 centers on making libraries easier to package and obtain. A new source-library target bundles C3 code into a distributable .c3l archive, while the new fetch command can search repositories, inspect versions and checksums, and download selected releases. Repositories need only serve a small set of JSON and download endpoints, so static hosting is sufficient; the default repository uses GitHub. Downloads are checked against SHA-256 hashes, and projects can pin versions or exact checksums. Dependencies can identify repository libraries, and a project command reports or fetches missing ones. This replaces the older vendor-only fetching mechanism and removes its single-source and versioning limitations.

The release also reduces safe-mode executable sizes by 30% or more by reusing panic-handling code rather than generating separate reporting logic for every check. Custom panic handlers must adopt a revised function signature, and panic configuration now behaves more consistently. A review of type conversions fixes compiler defects and makes several conversions require explicit casts, including signed-to-unsigned conversions and conversions between bfloat and float16; out-of-range constant conversions now fail at compile time. Else-if branches must use braces, and repeated designated initializers are rejected. Other improvements identify which generic instantiation caused an error, add detailed compilation statistics, allow project targets to declare build order, and support environment-variable substitution in project files.

Read on c3-lang.org0 comments on Hacker News

Summary generated by AI from the linked article. hn.today is not affiliated with Hacker News or Y Combinator.

More in Programming

Aristotle Expands into Rust

Aristotle Expands into Rust

Aristotle has expanded its formal verification platform to Rust, allowing developers to prove code meets specifications and contains no undefined behavior, including in unsafe blocks. It can also verify that Rust rewrites behave like their original C code, targeting critical software such as smart contracts and infrastructure. (harmonic.fun)

The daily digest

Today's best Hacker News stories, summarized and screenshotted, one email a day.