mirror of
https://github.com/wren-lang/wren.git
synced 2026-01-16 20:28:04 +01:00
Generating a runtime error on subclassing of builtins
As discussed in https://github.com/munificent/wren/issues/70, it is not allowed to subclass built-in types.
This commit is contained in:
2
test/string/subclassing_string.wren
Normal file
2
test/string/subclassing_string.wren
Normal file
@ -0,0 +1,2 @@
|
||||
class SubString is String {} // expect runtime error: Class 'SubString' may not subclass a built-in
|
||||
|
||||
Reference in New Issue
Block a user