Jade Lovelace af99ede1fd fix: UB casts to unspecified width enums in proto
Found by edef's fuzzing. We::jade don't think this is security-relevant
or likely to be mistreated by a compiler, but UB is bad.

https://eel.is/c++draft/expr.static.cast#8

> If the enumeration type does not have a fixed underlying type, the value is unchanged if the original value is within the range of the enumeration values ([dcl.enum]), and otherwise, the behavior is undefined

Notably, the range is defined as the smallest bitfield type that could hold all the values, not any real type which exists: https://eel.is/c++draft/dcl.enum#8.

This is basically a footgun, and I'm writing a clang-tidy check to forbid casting to such types. But first I needed to write clang-tidy testing infrastructure: https://gerrit.lix.systems/c/lix/+/5493.

Change-Id: Ieaaa0fe2a92fd9f24f60761e312741186a6a6964
2026-04-22 10:52:04 +00:00
2025-09-29 15:22:41 +02:00
2026-01-30 17:29:51 +00:00
2025-12-17 20:59:59 +01:00
2026-04-20 16:08:22 +00:00
2025-12-29 21:24:05 +00:00
2026-01-31 20:59:02 +00:00
2024-03-29 22:57:40 -07:00
2025-12-17 20:59:59 +01:00
2026-03-11 11:21:11 +00:00
2026-04-13 22:46:30 +01:00
2025-03-18 04:20:00 +00:00
2026-01-10 00:07:33 +00:00

Lix

Lix is an implementation of Nix, a powerful package management system for Linux and other Unix systems that makes package management reliable and reproducible.

Read more about us at https://lix.systems.

Installation

On Linux and macOS the easiest way to install Lix is to run the following shell command (as a user other than root):

$ curl -sSf -L https://install.lix.systems/lix | sh -s -- install

For systems that already have a Nix implementation installed, such as NixOS systems, read our install page

Building And Developing

See our Hacking guide in our manual for instruction on how to set up a development environment and build Lix from source.

Additional Resources

License

Lix is released under LGPL-2.1-or-later.

S
Description
Working fork of Lix - carries the adaptive load-aware build-remote patch. Upstream: gerrit.lix.systems
Readme
92 MiB
Languages
C++ 74.9%
Python 11.7%
Nix 6.1%
Shell 3.6%
Meson 2%
Other 1.6%