infinisil changed the topic of #nix-lang to: Channel for discussing Nix as a language - https://nixos.org/nix/manual/#chap-writing-nix-expressions - Logs: https://logs.nix.samueldr.com/nix-lang/
ddellacosta has quit [Ping timeout: 246 seconds]
andi- has quit [Remote host closed the connection]
andi- has joined #nix-lang
inara` has quit [Quit: Leaving]
inara has joined #nix-lang
MichaelRaskin has quit [Ping timeout: 258 seconds]
MichaelRaskin has joined #nix-lang
hmpffff has joined #nix-lang
hmpffff_ has joined #nix-lang
hmpffff has quit [Ping timeout: 246 seconds]
__monty__ has joined #nix-lang
MichaelRaskin has quit [Quit: MichaelRaskin]
hmpffff has joined #nix-lang
hmpffff_ has quit [Ping timeout: 250 seconds]
ddellacosta has joined #nix-lang
hmpffff has quit [Remote host closed the connection]
hmpffff has joined #nix-lang
{`-`} has joined #nix-lang
{`-`} has joined #nix-lang
hmpffff has quit [Read error: Connection reset by peer]
hmpffff has joined #nix-lang
<infinisil> > __curPos
<{^_^}> { column = 1; file = "(string)"; line = 289; }
<infinisil> :o
<infinisil> > __curPos
<{^_^}> { column = 1; file = "(string)"; line = 289; }
<infinisil> > " ${lib.generators.toPretty {} __curPos}"
<{^_^}> " { \"column\" = 45; \"file\" = \"(string)\"; \"line\" = 289; }"
<infinisil> > lib.generators.toPretty {} __curPos
<{^_^}> "{ \"column\" = 28; \"file\" = \"(string)\"; \"line\" = 289; }"
<infinisil> So it *is* possible to easily get the current file!
<infinisil> > __curPos.file
<{^_^}> "(string)"
<infinisil> > map (mapAttrs null) [ 0 ]
<{^_^}> [ <CODE> ]
<infinisil> > :p map (mapAttrs null) [ 0 ]
<{^_^}> error: value is an integer while a set was expected, at undefined position
<infinisil> > :p map (x: mapAttrs null x) [ 0 ]
<{^_^}> value is an integer while a set was expected, at (string):289:9
<infinisil> Unfortunate side effect of passing a builtin function directly instead of declaring a lambda.. ^
<infinisil> (the error is really bad)
__monty__ has quit [Quit: leaving]
hmpffff has quit [Quit: Bye…]
hmpffff has joined #nix-lang
hmpffff has quit [Client Quit]
kyren has quit [Quit: ZNC 1.7.4 - https://znc.in]
kyren has joined #nix-lang