1
0
mirror of https://github.com/YosysHQ/nextpnr.git synced 2026-02-06 08:35:08 +00:00

Merge pull request #108 from dlharmon/master

Improve error reporting of failure to open JSON file
This commit is contained in:
Clifford Wolf
2018-11-12 09:09:57 +01:00
committed by GitHub

View File

@@ -749,6 +749,10 @@ bool parse_json_file(std::istream &f, std::string &filename, Context *ctx)
{
try {
using namespace JsonParser;
if (!f)
log_error("failed to open JSON file.\n");
int lineno = 1;
JsonNode root(f, lineno);