Bob Nystrom
d7d067b960
feat: prevent subclassing of built-in types with runtime error
...
Add a check in the interpreter's class creation path that rejects attempts to subclass any of the seven core built-in types (Class, Fiber, Fn, List, Map, Range, String). When such a subclass is declared, a runtime error is raised with a message like "Class 'SubName' may not subclass a built-in". Also add corresponding test files for each forbidden subclass scenario.
2015-02-27 15:41:25 +00:00
..
2015-01-01 18:40:14 +00:00
2015-01-01 18:40:14 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2014-04-14 14:23:05 +00:00
2014-04-14 14:23:05 +00:00
2014-04-14 14:23:05 +00:00
2014-04-14 14:23:05 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2014-04-05 01:24:55 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2014-04-14 14:23:05 +00:00
2015-02-27 07:08:36 +00:00
2015-02-25 19:13:37 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2014-04-05 01:24:55 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2014-01-13 14:58:27 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00
2015-02-27 07:08:36 +00:00