Skip to content
This repository was archived by the owner on Sep 7, 2021. It is now read-only.

Commit e8561d8

Browse files
authored
Merge pull request livecode#1258 from livecode/feature-better_dependency_error
[[ IDE ]] Include info about file that causes dependency check error
2 parents cbd8243 + 457de3e commit e8561d8

1 file changed

Lines changed: 12 additions & 11 deletions

File tree

Toolset/libraries/revidelibrary.8.livecodescript

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -11276,17 +11276,17 @@ private function __ScanFileMTime pFilename, pRecursive, pAllowMissing, \
1127611276
if tDirname is empty then
1127711277
put "." into tDirname
1127811278
end if
11279-
11279+
1128011280
if tBasename is empty then
11281-
throw "Failed to check modification time: invalid filename"
11281+
throw "Failed to check modification time: invalid filename" && pFilename
1128211282
end if
11283-
11283+
1128411284
-- Regular file
1128511285
local tMTime
1128611286
if there is a file pFilename then
1128711287
put revIDELastModifiedTimeOfFile(tDirname, tBasename) into tMTime
1128811288
if tMTime is empty then
11289-
throw "Failed to check modification time for file"
11289+
throw "Failed to check modification time for file" && pFilename
1129011290
end if
1129111291
if tMTime < xMin then
1129211292
put tMTime into xMin
@@ -11305,21 +11305,22 @@ private function __ScanFileMTime pFilename, pRecursive, pAllowMissing, \
1130511305
-- List directory contents
1130611306
revIDEPushDefaultFolder pFilename
1130711307
if the result is not empty then
11308-
throw "Failed to set default folder"
11308+
throw "Failed to set default folder" && pFilename
1130911309
end if
1131011310

1131111311
put files() & return & folders() into tContents
1131211312
filter tContents without ".."
11313-
11313+
filter tContents without empty
11314+
1131411315
revIDEPopDefaultFolder pFilename
1131511316
if the result is not empty then
11316-
throw "Failed to set default folder"
11317+
throw "Failed to set default folder" && pFilename
1131711318
end if
11318-
11319+
1131911320
if tContents is empty then
1132011321
return true
1132111322
end if
11322-
11323+
1132311324
-- Recursively scan files & folders
1132411325
repeat for each line tInnerFilename in tContents
1132511326
put pFilename & slash before tInnerFilename
@@ -11330,14 +11331,14 @@ private function __ScanFileMTime pFilename, pRecursive, pAllowMissing, \
1133011331

1133111332
return true
1133211333
else
11333-
throw "Failed to check modification time: unexpected folder"
11334+
throw "Failed to check modification time: unexpected folder" && pFilename
1133411335
end if
1133511336
end if
1133611337

1133711338
-- Missing
1133811339
if pAllowMissing then
1133911340
return false
1134011341
else
11341-
throw "Failed to check modification time: missing file"
11342+
throw "Failed to check modification time: missing file" && pFilename
1134211343
end if
1134311344
end __ScanFileMTime

0 commit comments

Comments
 (0)