Skip to content

Commit e1ebc9c

Browse files
committed
Merge remote-tracking branch 'origin/tristan/harden-defs-db'
2 parents 076f667 + fc233aa commit e1ebc9c

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

compiler/front-end.stanza

+2-1
Original file line numberDiff line numberDiff line change
@@ -614,7 +614,8 @@ defn FrontEnd (sys:FrontEndInputs) -> FrontEnd :
614614
if add(added-set, name(p)) : true
615615
else : add(duplicates, name(p))
616616
if not empty?(duplicates) :
617-
throw(DuplicatePackages(to-tuple(duplicates)))
617+
vprintln("Warning: dropping duplicate packages %_" % [to-tuple(duplicates)])
618+
add(errors, DuplicatePackages(to-tuple(duplicates)))
618619
ps*
619620

620621
defn check-already-loaded (ps:Seqable<IPackage|Pkg>, errors:Vector<Exception>) -> Tuple<IPackage|Pkg> :

compiler/main.stanza

+4-2
Original file line numberDiff line numberDiff line change
@@ -1119,12 +1119,14 @@ defn defs-db-command () :
11191119
get?(cmd-args, "macros", [])) ;macro-plugin
11201120

11211121
;Launch!
1122-
run-with-timing-log(main, cmd-args)
1122+
within run-with-timing-log(cmd-args) :
1123+
within run-with-verbose-flag(cmd-args) :
1124+
main()
11231125

11241126
;Command definition
11251127
Command("definitions-database",
11261128
AtLeastOneArg, "the .proj files to use to generate definitions for.",
1127-
to-tuple $ cat(new-flags, common-stanza-flags(["platform", "flags", "optimize", "macros", "timing-log"])),
1129+
to-tuple $ cat(new-flags, common-stanza-flags(["platform", "flags", "optimize", "verbose", "macros", "timing-log"])),
11281130
defs-db-msg, false, verify-args, intercept-no-match-exceptions(defs-db-action))
11291131

11301132

0 commit comments

Comments
 (0)