{"action":"created","issue":{"url":"https://api.github.com/repos/micropython/micropython/issues/1779","labels_url":"https://api.github.com/repos/micropython/micropython/issues/1779/labels{/name}","comments_url":"https://api.github.com/repos/micropython/micropython/issues/1779/comments","events_url":"https://api.github.com/repos/micropython/micropython/issues/1779/events","html_url":"https://github.com/micropython/micropython/pull/1779","id":126413033,"number":1779,"title":"full kwargs handling for property()","user":{"login":"chrysn","id":442326,"avatar_url":"https://avatars.githubusercontent.com/u/442326?v=3","gravatar_id":"","url":"https://api.github.com/users/chrysn","html_url":"https://github.com/chrysn","followers_url":"https://api.github.com/users/chrysn/followers","following_url":"https://api.github.com/users/chrysn/following{/other_user}","gists_url":"https://api.github.com/users/chrysn/gists{/gist_id}","starred_url":"https://api.github.com/users/chrysn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chrysn/subscriptions","organizations_url":"https://api.github.com/users/chrysn/orgs","repos_url":"https://api.github.com/users/chrysn/repos","events_url":"https://api.github.com/users/chrysn/events{/privacy}","received_events_url":"https://api.github.com/users/chrysn/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":10,"created_at":"2016-01-13T12:58:46Z","updated_at":"2016-01-13T17:37:06Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/micropython/micropython/pulls/1779","html_url":"https://github.com/micropython/micropython/pull/1779","diff_url":"https://github.com/micropython/micropython/pull/1779.diff","patch_url":"https://github.com/micropython/micropython/pull/1779.patch"},"body":"given it simplifies the handling of different numbers of arguments (deleted code portion), i'd offer this as my preferred solution to #1778, providing maximum compatibility with cpython at the cost of four additional qstr, and probably slightly increased stack size and runtime for property calls (not measured)."},"comment":{"url":"https://api.github.com/repos/micropython/micropython/issues/comments/171374434","html_url":"https://github.com/micropython/micropython/pull/1779#issuecomment-171374434","issue_url":"https://api.github.com/repos/micropython/micropython/issues/1779","id":171374434,"user":{"login":"chrysn","id":442326,"avatar_url":"https://avatars.githubusercontent.com/u/442326?v=3","gravatar_id":"","url":"https://api.github.com/users/chrysn","html_url":"https://github.com/chrysn","followers_url":"https://api.github.com/users/chrysn/followers","following_url":"https://api.github.com/users/chrysn/following{/other_user}","gists_url":"https://api.github.com/users/chrysn/gists{/gist_id}","starred_url":"https://api.github.com/users/chrysn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chrysn/subscriptions","organizations_url":"https://api.github.com/users/chrysn/orgs","repos_url":"https://api.github.com/users/chrysn/repos","events_url":"https://api.github.com/users/chrysn/events{/privacy}","received_events_url":"https://api.github.com/users/chrysn/received_events","type":"User","site_admin":false},"created_at":"2016-01-13T17:37:06Z","updated_at":"2016-01-13T17:37:06Z","body":"> You should use mp_arg_parse_all_kw_array instead of mp_arg_parse_all.\n> That will also help to reduce code size.\n\ngreat, that's what i've been looking for.\n\n> Can you please report sizes with that?\n\nlatest unix is down to 349737 (+32 relative to original), stmhal to\n282636 (+44 relative to original).\n\n> I'd rather go the empty qstr route for fget/fset/fdel\n\ndone\n\n> we can make is to use only 16 bits for the qstr and flags members in\n> the mp_arg_t struct\n\nnot that it'll happen in this pull request, but for comparison: unix\nwent to 349625 (112 bytes saved), stmhal to 282224 (412 bytes saved)\nwith no compiler warnings when setting the members to uint16_t; unix\ntests passed.\n\nOn Wed, Jan 13, 2016 at 09:05:05AM -0800, Damien George wrote:\n> enum { ARG_fget, ARG_fset, ARG_fdel, ARG_doc };\n\ndone\n\n> That looks like legal and portable C.\n\ni looked it up: enums are guaranteed to start at 0 and increment by 1.\n\nin parallel to this pull request, which gets updated by the changes you\nsuggested, i've issuing a single-patch version #1780 (my preference for\nfine-grained commits is not shared by everybody); merge and reject as\nyou like.\n"}}