{"action":"created","issue":{"url":"https://api.github.com/repos/HaxeFoundation/haxe/issues/5422","repository_url":"https://api.github.com/repos/HaxeFoundation/haxe","labels_url":"https://api.github.com/repos/HaxeFoundation/haxe/issues/5422/labels{/name}","comments_url":"https://api.github.com/repos/HaxeFoundation/haxe/issues/5422/comments","events_url":"https://api.github.com/repos/HaxeFoundation/haxe/issues/5422/events","html_url":"https://github.com/HaxeFoundation/haxe/issues/5422","id":163336810,"number":5422,"title":"Error #1053: Illegal override, and Error #1065: Variable boot_5fbf is not defined","user":{"login":"aliokan","id":3050307,"avatar_url":"https://avatars.githubusercontent.com/u/3050307?v=3","gravatar_id":"","url":"https://api.github.com/users/aliokan","html_url":"https://github.com/aliokan","followers_url":"https://api.github.com/users/aliokan/followers","following_url":"https://api.github.com/users/aliokan/following{/other_user}","gists_url":"https://api.github.com/users/aliokan/gists{/gist_id}","starred_url":"https://api.github.com/users/aliokan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aliokan/subscriptions","organizations_url":"https://api.github.com/users/aliokan/orgs","repos_url":"https://api.github.com/users/aliokan/repos","events_url":"https://api.github.com/users/aliokan/events{/privacy}","received_events_url":"https://api.github.com/users/aliokan/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-07-01T07:35:23Z","updated_at":"2016-07-01T08:33:47Z","closed_at":null,"body":"Hello, \r\n\r\nI met theses issues when I override a method declared in AS3 class embedded in a SWC, and between the AS3 class, and the class that override I have another Haxe class. \r\n\r\nWith an example, it will be more understandable ;)\r\n\r\n**In SWC**\r\n```actionscript\r\npublic class ClassA\r\n{\r\n\tprotected function init() : void\r\n\t{\r\n\t}\r\n}\r\n```\r\n\r\n**In Haxe project**\r\n```haxe\r\nclass ClassB extends ClassA\r\n{\r\n\tpublic function new() \r\n\t{\r\n\t\tsuper();\r\n\t}\t\r\n}\r\n```\r\n```haxe\r\nclass ClassC extends ClassB\r\n{\r\n\tpublic function new() \r\n\t{\r\n\t\tsuper();\r\n\t}\r\n\t\r\n\toverride private function init() : Void\r\n\t{\r\n\t}\r\n}\r\n```\r\n\r\n**Runetime issue**\r\n```console\r\n[Fault] exception, information=VerifyError: Error #1053: Illegal override of init in ClassC.\r\n[Fault] exception, information=ReferenceError: Error #1065: Variable boot_5fbf is not defined.\r\n```\r\n\r\nSame result with haxe 3.2.1, 3.0.0-rc1 and nightly build. \r\nTarget Flash 11.5, run on Flash Player 22.\r\n\r\nFind in attachment swf and HaxeDevelop project. \r\n\r\n[swf.zip](https://github.com/HaxeFoundation/haxe/files/343016/swf.zip)\r\n[haxedevelop-project.zip](https://github.com/HaxeFoundation/haxe/files/343017/haxe-189.zip)\r\n"},"comment":{"url":"https://api.github.com/repos/HaxeFoundation/haxe/issues/comments/229889098","html_url":"https://github.com/HaxeFoundation/haxe/issues/5422#issuecomment-229889098","issue_url":"https://api.github.com/repos/HaxeFoundation/haxe/issues/5422","id":229889098,"user":{"login":"aliokan","id":3050307,"avatar_url":"https://avatars.githubusercontent.com/u/3050307?v=3","gravatar_id":"","url":"https://api.github.com/users/aliokan","html_url":"https://github.com/aliokan","followers_url":"https://api.github.com/users/aliokan/followers","following_url":"https://api.github.com/users/aliokan/following{/other_user}","gists_url":"https://api.github.com/users/aliokan/gists{/gist_id}","starred_url":"https://api.github.com/users/aliokan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aliokan/subscriptions","organizations_url":"https://api.github.com/users/aliokan/orgs","repos_url":"https://api.github.com/users/aliokan/repos","events_url":"https://api.github.com/users/aliokan/events{/privacy}","received_events_url":"https://api.github.com/users/aliokan/received_events","type":"User","site_admin":false},"created_at":"2016-07-01T08:33:47Z","updated_at":"2016-07-01T08:33:47Z","body":"The same result, if I decompile swf without @:protected, the definition of ClassC.init is correct.\r\n\r\nResult With SWFDecompiler : \r\n```actionscript\r\npackage \r\n{\r\n    import ClassA.*;\r\n\r\n    public class ClassA extends Object\r\n    {\r\n\r\n        public function ClassA()\r\n        {\r\n            return;\r\n        }// end function\r\n\r\n        protected function init() : void\r\n        {\r\n            return;\r\n        }// end function\r\n\r\n    }\r\n}\r\n```\r\n```actionscript\r\npackage \r\n{\r\n\r\n    public class ClassB extends ClassA\r\n    {\r\n\r\n        public function ClassB() : void\r\n        {\r\n            return;\r\n        }// end function\r\n\r\n    }\r\n}\r\n```\r\n```actionscript\r\npackage \r\n{\r\n    import ClassC.*;\r\n\r\n    public class ClassC extends ClassB\r\n    {\r\n\r\n        public function ClassC() : void\r\n        {\r\n            return;\r\n        }// end function\r\n\r\n        override protected function init() : void\r\n        {\r\n            return;\r\n        }// end function\r\n\r\n    }\r\n}\r\n```"}}
{"actor":{"display_login":"aliokan"}}