bounded serialization of CLR type references NYI #117

Closed
jaffa4 opened this Issue Apr 16, 2012 · 2 comments

Projects

None yet

2 participants

@jaffa4
jaffa4 commented Apr 16, 2012

Hi,
I tried this. It looks like a bug.
It runs without -c flag.
https://github.com/sorear/niecza/blob/master/examples/notepad.pl

It does not run in this way:

Niecza.exe -c D:\m\perlscripts\tests\perl6test\clr.p6
Unhandled exception: System.NotImplementedException: System.Object
at Niecza.P6opaque.FreezeSelf(FreezeBuffer fb, Type t)
at Niecza.BoxObject`1.Freeze(FreezeBuffer fb)
at Niecza.Serialization.FreezeBuffer.ObjRef(Object o)
at Niecza.Serialization.FreezeBuffer.ObjRef(Object o)
at Niecza.StashEnt.Niecza.Serialization.IFreeze.Freeze(FreezeBuffer fb)
at Niecza.Serialization.FreezeBuffer.ObjRef(Object o)
at Niecza.RuntimeUnit.Niecza.Serialization.IFreeze.Freeze(FreezeBuffer fb)
at Niecza.Serialization.FreezeBuffer.ObjRef(Object o)
at Niecza.Serialization.ObjectRegistry.SaveUnit(String name, IFreeze root)
at Niecza.RuntimeUnit.Save()
at Niecza.CLRBackend.DowncallReceiver.save_unit(Object[] args)
at Niecza.CLRBackend.DowncallReceiver.Call(Object[] args)
at Niecza.CLRBackend.DowncallReceiver.get_Item(Object i)
at D:\src\niecza\niecza\src\NieczaFrontendSTD.pm6 line 278 (ANON @ 3)
at line 0 (ExitRunloop @ 0)
at D:\src\niecza\niecza\src\NieczaFrontendSTD.pm6 line 0 (NieczaFrontendSTD.parse @ 62)
at D:\src\niecza\niecza\src\NieczaCompiler.pm6 line 35 (NieczaCompiler.compile @ 7)
at D:\src\niecza\niecza\src\NieczaCompiler.pm6 line 62 (NieczaCompiler.compile_file @ 6)
at D:\src\niecza\niecza\src\niecza line 166 (mainline @ 77)
at D:\src\niecza\niecza\boot\lib\CORE.setting line 3842 (ANON @ 3)
at D:\src\niecza\niecza\boot\lib\CORE.setting line 3843 (module-CORE @ 65)
at D:\src\niecza\niecza\boot\lib\CORE.setting line 3843 (mainline @ 2)
at line 0 (ExitRunloop @ 0)

@sorear
Owner
sorear commented Apr 17, 2012

I don't currently know how this can be fixed. It can be worked around by changing constant to my.

@jaffa4
jaffa4 commented Apr 17, 2012

that is something.

@sorear sorear added a commit that closed this issue May 26, 2012
@sorear A scheme for serializing CLR wrappers (fixes #117)
Based on the generic reference serialization scheme.  Not foolproof;
attempting to serialize a reference to a method will still blow up.
69f2cee
@sorear sorear closed this in 69f2cee May 26, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment