Skip to content

Commit

Permalink
PathConfig validator now gives more precise error message
Browse files Browse the repository at this point in the history
  • Loading branch information
PaulKlint committed Mar 12, 2024
1 parent 6549275 commit 55c18b4
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/org/rascalmpl/core/library/lang/rascalcore/check/Checker.rsc
Original file line number Diff line number Diff line change
Expand Up @@ -179,24 +179,24 @@ list[Message] validatePathConfigForCompiler(PathConfig pcfg, loc mloc) {
if(!exists(pcfg.bin)) {
try {
mkDirectory(pcfg.resources);
} catch _: {
msgs += error("PathConfig `bin`: <pcfg.bin> does not exist", pcfg.bin);
} catch e: {
msgs += error("PathConfig `bin`: <e>", pcfg.bin);
}
}

if(!exists(pcfg.resources)) {
try {
mkDirectory(pcfg.resources);
} catch _: {
msgs += error("PathConfig `resources`: <pcfg.resources> does not exist", pcfg.resources);
} catch e: {
msgs += error("PathConfig `resources`: <e>", pcfg.resources);
}
}

if(!exists(pcfg.generatedSources))
try {
mkDirectory(pcfg.generatedSources);
} catch _: {
msgs += error("PathConfig `generatedSources`: <pcfg.generatedSources> does not exist", pcfg.generatedSources);
} catch e: {
msgs += error("PathConfig `generatedSources`: <e>", pcfg.generatedSources);
}

return msgs;
Expand Down

0 comments on commit 55c18b4

Please sign in to comment.