Error when serilizing class with FuelMetalevel
needs FuelMetalevel loaded:
(ConfigurationOfFuel project version: '1.9') load: #(FuelMetalevel).
Code to reproduce:
aClass := Object subclass: #A category: 'Temporary'.
aSerializer := FLSerializer newDefault.
aSerializer analyzer considerInternalAllBehaviors: {aClass}.
aSerializer serialize: { aClass new } on: ByteArray new writeStream.
Max, you were right: It is because of FLAnalysis>>run:
objectStack push: root.
[ objectStack isEmpty ]
whileFalse: [ self mapAndTrace: objectStack pop ].
[ privateObjectStack isEmpty ]
whileFalse: [ self privateMapAndTrace: privateObjectStack pop ].
reason:
classes go to the privateObjectStack, but they add objects to the objectStack,
which is never never consumed.
a workaround is to reference the class directly from the graph. In the example:
aSerializer serialize: { aClass. aClass new } on: ByteArray new writeStream.
Original issue reported on code.google.com by [email protected] on 15 Apr 2013 at 2:11
This issue has been automatically marked as stale because it has not had recent activity. It will remain open but will probably not come into focus. If you still think this should receive some attention, leave a comment. Thank you for your contributions.
Write a test for this.
This issue has been automatically marked as stale because it has not had recent activity. It will remain open but will probably not come into focus. If you still think this should receive some attention, leave a comment. Thank you for your contributions.
Not stale.
This issue has been automatically marked as stale because it has not had recent activity. It will remain open but will probably not come into focus. If you still think this should receive some attention, leave a comment. Thank you for your contributions.
Not stale