brewery
notashelf /
eb84d4617bc5fbc7e072d5d031248a021b618af3

nixir

public

Import-resolving Nix IR plugin

Star0tarball
clone
ssh://git@git.notashelf.dev:33/notashelf/nixir.git
tests/precedence.nixNix8 lines308 B
1
# Test operator precedence
2
let
3
  a = 1 + 2 * 3;        # Should be 1 + (2 * 3) = 7
4
  b = 10 - 5 - 2;       # Should be (10 - 5) - 2 = 3
5
  c = true && false || true;  # Should be (true && false) || true = true
6
  d = 1 < 2 && 3 > 2;   # Should be (1 < 2) && (3 > 2) = true
7
in
8
  { a = a; b = b; c = c; d = d; }