File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed
Clojure/Clojure/CljCompiler Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -39,6 +39,23 @@ public static class Compiler
3939 static readonly Dictionary < String , Type > _evalTypeMap = new Dictionary < string , Type > ( ) ;
4040 static readonly Dictionary < String , Type > _compilerTypeMap = new Dictionary < string , Type > ( ) ;
4141
42+ #if NETFRAMEWORK
43+
44+ // preserve the original versions of these methods under NETFRAMEWORK.
45+ // Otherwise, we viodate the tests of CLJ-979 in test_clojure/compilation2.
46+ // This may be unavoidable in .Net 9.0 and later.
47+
48+ internal static void RegisterDuplicateType ( Type type )
49+ {
50+ _evalTypeMap [ type . FullName ] = type ;
51+ }
52+
53+ internal static Type FindDuplicateType ( string typename )
54+ {
55+ _evalTypeMap . TryGetValue ( typename , out Type type ) ;
56+ return type ;
57+ }
58+ #else
4259 internal static void RegisterDuplicateType ( Type type )
4360 {
4461 if ( Compiler . IsCompiling )
@@ -55,6 +72,7 @@ internal static Type FindDuplicateType(string typename)
5572 _evalTypeMap . TryGetValue ( typename , out Type type ) ;
5673 return type ;
5774 }
75+ #endif
5876
5977 #endregion
6078
You can’t perform that action at this time.
0 commit comments