jfrijters
ed39d39fe3
Apply custom attribute annotations on annotation types to the corresponding custom attribute that is generated (and allow AttributeUsageAttribute to override the default AttributeUsageAttribute generated from the @Target annotation).
2012-08-15 11:52:55 +00:00
jfrijters
15d12a5439
Stop using ConstructorBuilder (always use MethodBuilder).
2012-08-15 08:45:39 +00:00
jfrijters
d15c9e3590
Moved GhostMethodWrapper out of MethodWrapper and removed MethodWrapper.Create() as it was used in only one place.
2012-08-06 15:40:12 +00:00
jfrijters
8202009fca
Merged CodeEmitter.Emit(OpCode, MethodInfo) and CodeEmitter.Emit(OpCode, ConstructorInfo) into CodeEmitter.Emit(OpCode, MethodBase) and removed unnecessary downcasting.
2012-08-06 13:01:41 +00:00
jfrijters
0e1544a6e7
- Marked MemberWrapper class abstract.
...
- Marked all classes that don't (and shouldn't) have subclasses sealed.
2012-08-06 12:12:03 +00:00
jfrijters
b8492e30a6
Bug fix. If a Java class extends a remapped .NET type (cli.System.Object or cli.System.Exception), we should correctly report the base class.
2012-07-21 06:35:51 +00:00
jfrijters
ca21edeb75
Fixed some minor class modifiers issues:
...
- stub generator now reproduces exact class modifier bits
- unused bits are now properly masked and returned
- non-abstract interfaces now properly return ACC_ABSTRACT
2012-07-09 06:07:39 +00:00
jfrijters
b015884acb
- Made CodeEmitter more "type safe" by adding specific EmitXxx methods instead of following the more general ILGenerator pattern.
...
- Added some new optimizations to CodeEmitter (disabled unless experimental optimizations are enabled).
- Added some invariant checks to CodeEmitter to help debug optimizations (and document the invariants).
2012-07-03 14:45:51 +00:00
jfrijters
94be3503c6
Bug fix. When resolving properties corresponding to fields with type 2 access stubs, unloadable types with the same name should compare as equal.
2012-06-11 15:41:37 +00:00
jfrijters
1011c474e7
Bug fix. When an unloadable type is used in a method signature that overrides a method (or implements an interface method), the custom modifier must be the same as the base class or an override stub must be generated.
2012-04-13 11:47:48 +00:00
jfrijters
b2b94c0221
Added support for type 2 access stubs for constructors.
2012-04-12 10:09:09 +00:00
jfrijters
3cfa691e6b
More ikvmc error handling clean up.
2012-03-25 09:10:28 +00:00
jfrijters
e3d95f6da5
Add support for delegates with ByRef parameters.
2012-01-20 09:01:07 +00:00
jfrijters
452433f1f8
Removed method name mangling and depend on custom modifiers instead.
2012-01-05 09:03:52 +00:00
jfrijters
da32b9ddb8
Made base TypeWrapper resolution lazy for compiled and .NET TypeWrappers. This is not just a perf improvement, but also avoid infinite recursion for generic type instantiations that use sub types as type parameters.
2012-01-03 14:26:36 +00:00
jfrijters
04b660834b
- Fixed regression introduced by earlier change. Type names should be unescaped.
...
- Suppress annotation custom attributes when enumerating inner classes.
2011-12-15 11:54:58 +00:00
jfrijters
7bb7d9886f
Removed class name length limitation.
2011-12-15 08:56:10 +00:00
jfrijters
933bdf2f97
Removed last remaining TypeAsBuilder usage.
2011-12-13 07:34:50 +00:00
jfrijters
e1e9b67cb4
SetNameSig is now only used with MethodBuilder.
2011-11-29 15:08:15 +00:00
jfrijters
f699705e6a
- Use custom modifiers (instead of NameSigAttribute) for constructors with mangled types.
...
- Fixed GetModOpt() to handle ghost arrays.
- Moved namesig handling for methods into GenerateMethod().
2011-11-29 13:00:26 +00:00
jfrijters
4f6de4245e
Don't mangle property accessor method names, but use a custom modifier instead.
2011-11-25 12:47:17 +00:00
jfrijters
050190d782
Stop mangling property names for access stubs (instead we rely on custom modifiers to make them unique).
2011-11-25 12:03:57 +00:00
jfrijters
60e2d4af9a
Use modopt to reliably correlate type 2 access stub properties with the underlying field. This fixes a bug where annotations applied to fields with type 2 access stubs would not be visible at runtime (via reflection).
2011-11-24 15:14:03 +00:00
jfrijters
27f408b3a4
Removed legacy remap feature that allowed final fields as properties to be defined (long time ago this was used for the System.in/out/err fields).
2011-11-24 12:31:38 +00:00
jfrijters
6dce5cc447
Instead of mangling field names and using NameSigAttribute, we now use modopt to modify the signature and record the real type.
2011-11-24 09:08:04 +00:00
jfrijters
917376e242
Added support for classes that represent arrays of remapped .NET types and .NET primitives.
2011-11-24 08:35:47 +00:00
jfrijters
e203aaf1f2
When generating an access stub for a bridge method, prefix the access stub with <bridge> as well (to avoid confusing any other compilers).
2011-11-23 07:09:29 +00:00
jfrijters
44c6177691
Implemented type 2 access stubs for methods (not constructors) and rewrote how type 1 access stubs are handled.
2011-11-23 06:20:34 +00:00
jfrijters
242461074d
Fixed several type 1 method access stub issues.
2011-11-18 15:22:46 +00:00
jfrijters
d95dc01122
Added support for type 1 access stub methods with non-public parameter/return types.
2011-11-18 08:33:55 +00:00
jfrijters
dcac5e5ef7
Bug fix. When calling a final method on a remapped type we can't call the instance method in the remapped type, but we have to call the instancehelper instead.
2011-10-18 10:57:18 +00:00
jfrijters
cc40abea83
Bug fix. TypeWrapper.IsAssignableTo() didn't handle arrays with primitive elements properly.
2011-08-12 07:51:00 +00:00
jfrijters
524bf7c090
Fix and enhancement. When a .NET type implements a shadowed interface, we now also publish the original interface (e.g. if the .NET type implements System.IComparable, Java code will now see java.lang.Comparable and System.IComparable). In addition, the new code makes sure that when a .NET type explicitly implements both System.IComparable and java.lang.Comparable that the Java code will not see java.lang.Comparable twice.
2011-06-27 15:13:20 +00:00
jfrijters
c742dbb2d9
Added support for declaring exceptions on shadow interface methods.
2011-06-27 13:15:17 +00:00
jfrijters
1246761ff5
Retain reflection field ordering for ikvmc compiled code (not required by spec, but to improve compatibility with broken code).
2011-05-17 07:46:01 +00:00
jfrijters
31e1f2dbc4
Clean up TypeWrapper.IsFakeNestedType and allow it to be called on unfinished TypeWrappers.
2011-01-21 11:06:26 +00:00
jfrijters
cec4f20c29
- Removed unnecessary methods from CodeEmitter.
...
- Removed "Lazy" prefixes in CodeEmitter.
2010-10-01 08:11:49 +00:00
jfrijters
3888406d95
Wrapped LocalBuilder in new CodeEmitterLocal class to allow CodeEmitter to encapsulate the ILGenerator fully.
2010-09-29 07:21:51 +00:00
jfrijters
b5709a3606
Changed workaround for gmcs inability to properly deal with two-pass compilation of mutually dependant assemblies to use reflection, because the previous workaround now also fails on Mono 2.8.
2010-09-21 05:45:48 +00:00
jfrijters
c75b9ffb8c
Renamed StaticCompiler.GetType() that is used exclusively by map.xml processing to make it more obvious and added error message (and abort the compile). The remaining StaticCompiler.GetType() now behaves more like Type.GetType() in that it returns null if the type isn't found.
2010-09-20 15:08:45 +00:00
jfrijters
3a5fc585a9
Added extra indirection thru MethodWrapper for intrinsic method call emitting to allow .NET delegate constructor optimization to use instrinsic infrastructure instead of requiring EmitNewobj to pass a MethodAnalyzer and opcode index.
2010-09-14 12:29:22 +00:00
jfrijters
2fc594a370
Added VerifierTypeWrapper.IsNotPresentOnStack() to encapsulate the notion of types that aren't represented on the .NET stack.
...
Note that while this may look like a bug fix (because we're handling fault block exception types in more places), it isn't. Fault block exceptions can not actually occur on the stack, because the verifier will only allow them in very limited places.
2010-09-13 06:16:23 +00:00
jfrijters
6b50942867
Fix for bug #3056721 .
2010-09-10 07:59:39 +00:00
jfrijters
17de2517f0
Types nested in a type that is HideFromJava should also be considered HideFromJava.
2010-07-28 12:33:22 +00:00
jfrijters
3fa99010ee
Made most static compiler warnings local to the target that is being compiled (in multi target mode), to allow warnings to be suppressed (or turned into an error) for a specific target.
2010-07-16 08:50:40 +00:00
jfrijters
d5e40dadf8
We need to pre-intern the magic strings that VerifierTypeWrapper uses as type names, because TypeWrapper will intern them in its constructor. Thanks to Andrey Malakov for tracking this down.
2010-06-10 04:38:57 +00:00
jfrijters
0ed13314f0
Implemented codegen improvement to use CLR fault handlers for Java catch all handlers, whenever possible.
2010-06-08 05:25:14 +00:00
jfrijters
aa80cfdecf
TypeWrapper.AssertFinished() doesn't make sense for the static compiler anymore.
2010-06-07 04:21:35 +00:00
jfrijters
1dc4ffa32b
More object -> java.lang.Class updates.
2010-05-27 10:54:34 +00:00
jfrijters
40dcf95916
More type safety. TypeWrapper.ClassObject is now typed as java.lang.Class.
2010-05-27 09:25:15 +00:00