| 14 Dec 2025 |
kloenk | psychic damage noises | 17:01:29 |
522 it/its ⛯ΘΔ | ... what's with this
# nix-instantiate --parse -E "01.4"
{
"_type": "ExprCall",
"args": [
{
"_type": "ExprLiteral",
"value": 0.4,
"valueType": "Float"
}
],
"fun": {
"_type": "ExprLiteral",
"value": 1,
"valueType": "Int"
}
}
... why is that not just a float literal with value 1.4
| 19:09:30 |
piegames | Quick poll: should function application without spaces be allowed? foo"1"2 | 19:09:36 |
piegames | In reply to @522_:catgirl.cloud
... what's with this
# nix-instantiate --parse -E "01.4"
{
"_type": "ExprCall",
"args": [
{
"_type": "ExprLiteral",
"value": 0.4,
"valueType": "Float"
}
],
"fun": {
"_type": "ExprLiteral",
"value": 1,
"valueType": "Int"
}
}
... why is that not just a float literal with value 1.4
Because it parses as fucking 01 .4 | 19:10:03 |
522 it/its ⛯ΘΔ | lol | 19:10:18 |
522 it/its ⛯ΘΔ | oh right it's presumably just not legal | 19:10:29 |
522 it/its ⛯ΘΔ | yeah | 19:10:35 |
piegames | In reply to @522_:catgirl.cloud lol Yeah because integers can have leading zeroes but not floats | 19:11:58 |
piegames | So floats with leading zeros of course parse as fucking function application | 19:12:21 |
helle (just a stray cat girl) | still slightly dislike nix does not have hex and oct literals from when we started using it first | 19:13:11 |
522 it/its ⛯ΘΔ | the error for 0xff being "you tried to call 0" is really funny | 19:14:31 |
helle (just a stray cat girl) | I know it so far has not really come up with anything we wrote, but still it was "okay, huh" | 19:14:50 |
piegames | Can't be added atm because 0x10 parses as 0 x10 | 19:15:15 |
piegames | So we can deprecate that syntax but can't give it new semantics without langver | 19:15:42 |
helle (just a stray cat girl) | yep, we know, and it rarely comes up | 19:16:10 |
helle (just a stray cat girl) | and nixpkgs brings lib.trivial.fromHexString, which I have used a total of once | 19:16:35 |
helle (just a stray cat girl) | octal, so far, never | 19:16:46 |
piegames | Because permissions are usually treated as strings | 19:22:27 |
helle (just a stray cat girl) | yep | 19:22:42 |
| lucy joined the room. | 22:20:42 |
crop | In reply to @522_:catgirl.cloud
... what's with this
# nix-instantiate --parse -E "01.4"
{
"_type": "ExprCall",
"args": [
{
"_type": "ExprLiteral",
"value": 0.4,
"valueType": "Float"
}
],
"fun": {
"_type": "ExprLiteral",
"value": 1,
"valueType": "Int"
}
}
... why is that not just a float literal with value 1.4
If all this would be made to behave more reasonable would this actually break things? | 23:13:19 |
| 15 Dec 2025 |
| n4ch723hr3r (putting stuff in your name is cringe) joined the room. | 00:11:14 |
raitobezarius | aloisw: unfortunately, i'm still overseas and jetlagged as fucked, so i was not able to touch it | 00:24:03 |
raitobezarius | i should be able to get back to you around ~21st-ish | 00:24:20 |
n4ch723hr3r (putting stuff in your name is cringe) | touch what? | 00:31:00 |
raitobezarius | another input: i believe we kinda have to offer a default solution with a sensible UX at some point, but we're still in the phase of extracting flakes, etc. to make a sense of the ecosystem, unify/simplify/improve then we can elect a default solution that people can settle on
and maybe a hot take but i think at that moment, it would be good if all npins/lon/niv/etc. projects could be subsumed by This New Thing™ except if it's proven that having multiple solutions is required (because flexibility, etc.), this won't prevent people from having customized tailor-made solutions via the plugin system, but this shouldn't be the default scenario
| 00:31:08 |
raitobezarius | touch this ^ | 00:31:25 |
KFears (burnt out) | I sometimes think about doing the New Thing, but I often stumbled into doing weird hacks or gross glue or re-implementations from scratch:
- A good New Thing might want to do flake-import, but flake inputs are a very restricted subset of NixLang, being able to get them as JSON would be super helpful
- Likewise, parsing flakerefs is not something exciting, and being able to turn flakerefs into JSON would be super helpful (flakes already understand both)
- Getting NAR hash, store path, etc. from an arbitrary file/dir often feels unnecessarily complicated, so instead of simple git clone and getting hash, there's often a need to shell out to nix-prefetch-helpers
| 00:55:20 |
KFears (burnt out) | I think if Lix provides an improved CLI, then creating New Thing will be much easier and pretty much just wiring things up together | 00:56:19 |
KFears (burnt out) | I haven't spent much time on the problem though, I think people who have done locking solutions can contribute more | 00:58:51 |