1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-25 14:51:16 +02:00

forceString: Show position info

This commit is contained in:
Eelco Dolstra 2014-04-04 21:14:11 +02:00
parent 27b44b8cf7
commit a5fe730940
6 changed files with 46 additions and 30 deletions

View file

@ -145,7 +145,7 @@ void ExprPos::show(std::ostream & str)
std::ostream & operator << (std::ostream & str, const Pos & pos)
{
if (!pos.line)
if (!pos)
str << "undefined position";
else
str << (format("%1%:%2%:%3%") % pos.file % pos.line % pos.column).str();