Skip to content

Commit c3157a7

Browse files
committedSep 5, 2014
Add a note about singleton classes inheritance
[skip ci]
1 parent 3b7a66d commit c3157a7

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed
 

‎opal/corelib/kernel.rb

+4
Original file line numberDiff line numberDiff line change
@@ -522,6 +522,10 @@ def singleton_class
522522
523523
// FIXME - is this right? (probably - methods defined on
524524
// class' singleton should also go to subclasses?)
525+
//
526+
// @elia says: Actually a class' singleton inherits from its superclass'
527+
// singleton that in turn inherits from Class;
528+
525529
meta._proto = self.constructor.prototype;
526530
527531
meta._isSingleton = true;

0 commit comments

Comments
 (0)
Please sign in to comment.