{ "id": "109233", "key": "TIMOB-12781", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [], "resolution": null, "resolutiondate": null, "created": "2013-02-05T22:54:23.000+0000", "priority": null, "labels": [ "exalture", "reprod" ], "versions": [], "issuelinks": [], "assignee": null, "updated": "2018-02-28T20:04:22.000+0000", "status": { "description": "The issue is open and ready for the assignee to start work on it.", "name": "Open", "id": "1", "statusCategory": { "id": 2, "key": "new", "colorName": "blue-gray", "name": "To Do" } }, "components": [ { "id": "10206", "name": "iOS", "description": "iOS Platform" } ], "description": "h6.Issue\r\nAn undefined key, which is starting with the character sequence \"get\", of an object of type TiUIWindow results in an undesired behaviour of {{typeof}}: \r\n\r\n{code} \r\n var foo1 = {}; \r\n Ti.API.debug( typeof foo1.hallo); \r\n Ti.API.debug( typeof foo1.getA); \r\n Ti.API.debug( typeof foo1.getB); \r\n Ti.API.debug( typeof foo1.geA); \r\n Ti.API.debug( typeof foo1.ge); \r\n Ti.API.debug(\"------\"); \r\n\r\n var foo2 = Ti.UI.createView({}); \r\n Ti.API.debug( typeof foo2.hallo); \r\n Ti.API.debug( typeof foo2.getA); \r\n Ti.API.debug( typeof foo2.getB); \r\n Ti.API.debug( typeof foo2.geA); \r\n Ti.API.debug( typeof foo2.ge); \r\n Ti.API.debug(\"------\"); \r\n {code} \r\n\r\nh6.Output: \r\n {code} \r\n [debug] undefined \r\n [debug] undefined \r\n [debug] undefined \r\n [debug] undefined \r\n [debug] undefined \r\n [debug] ------ \r\n [debug] undefined \r\n [debug] function \r\n [debug] function \r\n [debug] undefined \r\n [debug] undefined \r\n [debug] ------ \r\n {code} \r\n\r\nh6.No issue under Android.\r\n\r\nh6.Additional debugging:\r\n\r\n{code}\r\n\tvar foo2 = Ti.UI.createView({});\r\n\ttry {\r\n\t\tTi.API.debug( typeof foo2.hallo());\r\n\t} catch(e) {\r\n\t\tTi.API.error(\"couldn't resolve type\");\r\n\t}\r\n\ttry {\r\n\t\tTi.API.debug( typeof foo2.getA());\r\n\t} catch(e) {\r\n\t\tTi.API.error(\"couldn't resolve type\");\r\n\t}\r\n\ttry {\r\n\t\tTi.API.debug( typeof foo2.getB());\r\n\t} catch(e) {\r\n\t\tTi.API.error(\"couldn't resolve type\");\r\n\t}\r\n\ttry {\r\n\t\tTi.API.debug( typeof foo2.geA());\r\n\t} catch(e) {\r\n\t\tTi.API.error(\"couldn't resolve type\");\r\n\t}\r\n\ttry {\r\n\t\tTi.API.debug( typeof foo2.ge());\r\n\t} catch(e) {\r\n\t\tTi.API.error(\"couldn't resolve type\");\r\n\t}\r\n\tTi.API.debug(\"------\");\r\n{code}\r\n\r\nh6.Output:\r\n{code}\r\n[error] couldn't resolve type\r\n[debug] undefined\r\n[debug] undefined\r\n[error] couldn't resolve type\r\n[error] couldn't resolve type\r\n[debug] ------\r\n{code}", "attachment": [], "flagged": false, "summary": "iOS: Wrong result of typeof", "creator": { "name": "usr743n", "key": "usr743n", "displayName": "Hans Joachim", "active": true, "timeZone": "Europe/Berlin" }, "subtasks": [], "reporter": { "name": "usr743n", "key": "usr743n", "displayName": "Hans Joachim", "active": true, "timeZone": "Europe/Berlin" }, "environment": "OSX, 3.0.0.GA, iOS SDK 6.1", "comment": { "comments": [ { "id": "422827", "author": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "body": "I am unable to reproduce the first issue, however I have managed to reproduce a similar error for the second issue. This is the error;\r\n[ERROR] : couldn't resolve type\r\n[ERROR] : couldn't resolve type\r\n[ERROR] : couldn't resolve type\r\n\r\nThis was reproduced with the following environment;\r\niPhone 7 (10.2)\r\nStudio 4.9.0.201705302345\r\nTi SDK 6.1.1.v20170623141152\r\nAppc NPM 4.2.9\r\nAppc CLI 6.2.1\r\nTi CLI 5.0.13\r\nAlloy 1.9.11\r\nArrow 2.0.0\r\nXcode 8.2 (8C38)\r\nNode v4.8.2\r\nJava 1.8.0_131", "updateAuthor": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2017-06-26T20:42:39.000+0000", "updated": "2017-06-26T20:42:39.000+0000" } ], "maxResults": 1, "total": 1, "startAt": 0 } } }