Nix: Make nix repl accept commands ending with semicolon

Created on 11 Sep 2018  路  1Comment  路  Source: NixOS/nix

Actual:

nix-repl> 1 + 2
3

nix-repl> 1 + 2;
error: syntax error, unexpected ';', expecting $end, at (string):1:6

Expected

nix-repl> 1 + 2
3

nix-repl> 1 + 2;
3

Reason:

This will make it easier to paste code chunks from .nix files to nix repl

Most helpful comment

I disagree. I think this just leads to confusion about what an expression is. Expressions don't end in semicolons, only attributes do.

>All comments

I disagree. I think this just leads to confusion about what an expression is. Expressions don't end in semicolons, only attributes do.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

edolstra picture edolstra  路  96Comments

domenkozar picture domenkozar  路  53Comments

Profpatsch picture Profpatsch  路  73Comments

ryanbooker picture ryanbooker  路  34Comments

cbarrett picture cbarrett  路  49Comments