{"action":"created","issue":{"url":"https://api.github.com/repos/quattor/pan/issues/202","repository_url":"https://api.github.com/repos/quattor/pan","labels_url":"https://api.github.com/repos/quattor/pan/issues/202/labels{/name}","comments_url":"https://api.github.com/repos/quattor/pan/issues/202/comments","events_url":"https://api.github.com/repos/quattor/pan/issues/202/events","html_url":"https://github.com/quattor/pan/issues/202","id":321108529,"node_id":"MDU6SXNzdWUzMjExMDg1Mjk=","number":202,"title":"Return SELF by default when modified","user":{"login":"stdweird","id":1517606,"node_id":"MDQ6VXNlcjE1MTc2MDY=","avatar_url":"https://avatars3.githubusercontent.com/u/1517606?v=4","gravatar_id":"","url":"https://api.github.com/users/stdweird","html_url":"https://github.com/stdweird","followers_url":"https://api.github.com/users/stdweird/followers","following_url":"https://api.github.com/users/stdweird/following{/other_user}","gists_url":"https://api.github.com/users/stdweird/gists{/gist_id}","starred_url":"https://api.github.com/users/stdweird/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stdweird/subscriptions","organizations_url":"https://api.github.com/users/stdweird/orgs","repos_url":"https://api.github.com/users/stdweird/repos","events_url":"https://api.github.com/users/stdweird/events{/privacy}","received_events_url":"https://api.github.com/users/stdweird/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":7,"created_at":"2018-05-08T09:24:28Z","updated_at":"2018-10-29T15:30:30Z","closed_at":null,"author_association":"MEMBER","body":"(i'm clueless how hard this is to implement, but oh boy is this annoying behaviour)\r\n\r\nCurrently\r\n```\r\nobject template t;\r\n\"/a\" = {\r\n    SELF['b'] = 1;\r\n};\r\n```\r\ngives \r\n```\r\nevaluation error [/tmp/t.pan:2.1-4.2]\r\nexisting element of type nlist cannot be replaced by one of type long\r\n>>> call stack trace \r\n>>> [/tmp/t.pan:2.1-4.2]\r\n>>> ====================\r\n```\r\n\r\nbecuase the dml has missing `SELF` at the end.\r\n\r\ni would propose that when SELF is modified in a dml block, that by default SELF is returned at the end instead of last assigned value (or whatever the current default behaviour is).\r\n\r\ni guess noone modifies SELF and then returns something else, at least not intentionally."},"comment":{"url":"https://api.github.com/repos/quattor/pan/issues/comments/433955880","html_url":"https://github.com/quattor/pan/issues/202#issuecomment-433955880","issue_url":"https://api.github.com/repos/quattor/pan/issues/202","id":433955880,"node_id":"MDEyOklzc3VlQ29tbWVudDQzMzk1NTg4MA==","user":{"login":"ned21","id":278425,"node_id":"MDQ6VXNlcjI3ODQyNQ==","avatar_url":"https://avatars2.githubusercontent.com/u/278425?v=4","gravatar_id":"","url":"https://api.github.com/users/ned21","html_url":"https://github.com/ned21","followers_url":"https://api.github.com/users/ned21/followers","following_url":"https://api.github.com/users/ned21/following{/other_user}","gists_url":"https://api.github.com/users/ned21/gists{/gist_id}","starred_url":"https://api.github.com/users/ned21/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ned21/subscriptions","organizations_url":"https://api.github.com/users/ned21/orgs","repos_url":"https://api.github.com/users/ned21/repos","events_url":"https://api.github.com/users/ned21/events{/privacy}","received_events_url":"https://api.github.com/users/ned21/received_events","type":"User","site_admin":false},"created_at":"2018-10-29T15:30:30Z","updated_at":"2018-10-29T15:30:30Z","author_association":"CONTRIBUTOR","body":"```\r\n\"/a\" = if (SOMETHING) assign('b', dict(\"foo\", \"bar\", \"x\", \"y')) else SELF;\r\n```\r\n\r\nwill cause /a to be undef if SOMETHING is false, hence the extra acrobatics to check SELF and return SELF or null."}}
{"actor":{"display_login":"ned21"}}