Merge pull request #3898 from 9rnsr/fix13378

[REG2.066] Issue 13378 - Wrong failure of template value parameter deduction in IFTI
Merge pull request #3932 from 9rnsr/fix13400

[REG2.067a] Issue 13400 - Linking problems with bigints and std.functional.memoize
Merge pull request #3905 from 9rnsr/fix13379

[REG2.067a] Issue 13379 - Latest dmd fails with recursive template expansion in std.regex
Merge pull request #3918 from 9rnsr/fix13394

[REG2.066] Issue 13394 - invariant fail to link since 2.066 when using separate compilation
Merge pull request #3939 from 9rnsr/2.066

Cherry-picking commits from master to 2.066 branch (for the minor release 2.066.1)