Commit 149367e
Harlan Haskins
[ParseableInterfaces] Short-circuit module loading
Previously, the ParseableInterfaceModuleLoader relied on the assumption
that, if it returned `errc::not_supported`, it would fall through the
search paths and then move on to the SerializedModuleLoader. This did
not anticipate the possibility of a valid .swiftinterface coming later
in the search paths, which can cause issues for the standard library
which is in the resource-dir and should always be loaded from there.
Instead, make the module loading explicitly short-circuit when seeing
`errc::not_supported`, and document it.
Also add some more logging throughout `discoverLoadableModule` so we can
more easily catch issues like this in the future.
Fixes rdar://494793861 parent be48d64 commit 149367e
File tree
3 files changed
+59
-6
lines changed- include/swift/Serialization
- lib
- Frontend
- Serialization
3 files changed
+59
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
54 | 66 | | |
55 | 67 | | |
56 | 68 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
880 | 880 | | |
881 | 881 | | |
882 | 882 | | |
883 | | - | |
| 883 | + | |
| 884 | + | |
| 885 | + | |
| 886 | + | |
884 | 887 | | |
885 | 888 | | |
| 889 | + | |
| 890 | + | |
| 891 | + | |
| 892 | + | |
886 | 893 | | |
887 | 894 | | |
888 | 895 | | |
| 896 | + | |
| 897 | + | |
889 | 898 | | |
| 899 | + | |
| 900 | + | |
| 901 | + | |
890 | 902 | | |
891 | 903 | | |
892 | 904 | | |
| |||
899 | 911 | | |
900 | 912 | | |
901 | 913 | | |
902 | | - | |
903 | | - | |
| 914 | + | |
| 915 | + | |
| 916 | + | |
| 917 | + | |
| 918 | + | |
| 919 | + | |
| 920 | + | |
| 921 | + | |
| 922 | + | |
| 923 | + | |
904 | 924 | | |
905 | 925 | | |
906 | 926 | | |
907 | 927 | | |
908 | 928 | | |
909 | | - | |
| 929 | + | |
| 930 | + | |
910 | 931 | | |
911 | 932 | | |
912 | 933 | | |
913 | 934 | | |
914 | 935 | | |
915 | 936 | | |
916 | 937 | | |
917 | | - | |
| 938 | + | |
| 939 | + | |
| 940 | + | |
| 941 | + | |
918 | 942 | | |
| 943 | + | |
| 944 | + | |
| 945 | + | |
| 946 | + | |
919 | 947 | | |
920 | 948 | | |
921 | 949 | | |
| |||
1070 | 1098 | | |
1071 | 1099 | | |
1072 | 1100 | | |
1073 | | - | |
| 1101 | + | |
| 1102 | + | |
| 1103 | + | |
| 1104 | + | |
| 1105 | + | |
| 1106 | + | |
| 1107 | + | |
1074 | 1108 | | |
| 1109 | + | |
1075 | 1110 | | |
1076 | 1111 | | |
1077 | 1112 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
218 | 218 | | |
219 | 219 | | |
220 | 220 | | |
| 221 | + | |
| 222 | + | |
221 | 223 | | |
222 | 224 | | |
223 | 225 | | |
| |||
251 | 253 | | |
252 | 254 | | |
253 | 255 | | |
| 256 | + | |
| 257 | + | |
254 | 258 | | |
255 | 259 | | |
256 | 260 | | |
| |||
320 | 324 | | |
321 | 325 | | |
322 | 326 | | |
| 327 | + | |
| 328 | + | |
323 | 329 | | |
324 | 330 | | |
325 | 331 | | |
| |||
0 commit comments