{"action":"created","comment":{"url":"https://api.github.com/repos/graalvm/truffle/pulls/comments/53161547","id":53161547,"diff_hunk":"@@ -0,0 +1,51 @@\n+/*\n+ * Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.\n+ * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.\n+ *\n+ * This code is free software; you can redistribute it and/or modify it\n+ * under the terms of the GNU General Public License version 2 only, as\n+ * published by the Free Software Foundation.  Oracle designates this\n+ * particular file as subject to the \"Classpath\" exception as provided\n+ * by Oracle in the LICENSE file that accompanied this code.\n+ *\n+ * This code is distributed in the hope that it will be useful, but WITHOUT\n+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or\n+ * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License\n+ * version 2 for more details (a copy is included in the LICENSE file that\n+ * accompanied this code).\n+ *\n+ * You should have received a copy of the GNU General Public License version\n+ * 2 along with this work; if not, write to the Free Software Foundation,\n+ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.\n+ *\n+ * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA\n+ * or visit www.oracle.com if you need additional information or have any\n+ * questions.\n+ */\n+package com.oracle.truffle.api.object.dsl;\n+","path":"truffle/com.oracle.truffle.api.object.dsl/src/com/oracle/truffle/api/object/dsl/Volatile.java","position":26,"original_position":26,"commit_id":"54d17532a5df5a4b01acd4ae3232bb2f577c18f9","original_commit_id":"54d17532a5df5a4b01acd4ae3232bb2f577c18f9","user":{"login":"chrisseaton","id":341094,"avatar_url":"https://avatars.githubusercontent.com/u/341094?v=3","gravatar_id":"","url":"https://api.github.com/users/chrisseaton","html_url":"https://github.com/chrisseaton","followers_url":"https://api.github.com/users/chrisseaton/followers","following_url":"https://api.github.com/users/chrisseaton/following{/other_user}","gists_url":"https://api.github.com/users/chrisseaton/gists{/gist_id}","starred_url":"https://api.github.com/users/chrisseaton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chrisseaton/subscriptions","organizations_url":"https://api.github.com/users/chrisseaton/orgs","repos_url":"https://api.github.com/users/chrisseaton/repos","events_url":"https://api.github.com/users/chrisseaton/events{/privacy}","received_events_url":"https://api.github.com/users/chrisseaton/received_events","type":"User","site_admin":false},"body":"> Is there strong reason for the DSL being in separate module, package?\r\n\r\nIt just seemed like separate functionality so it made sense to isolate it. I did have a vague idea that we might want to build some layers here - where people can understand that there is core functionality, and then things built on top of that.\r\n\r\nI don't mind moving it to wherever, so if someone with a stronger opinion and a justification asks me to move it that's fine.","created_at":"2016-02-17T13:17:40Z","updated_at":"2016-02-17T13:17:40Z","html_url":"https://github.com/graalvm/truffle/pull/40#discussion_r53161547","pull_request_url":"https://api.github.com/repos/graalvm/truffle/pulls/40","_links":{"self":{"href":"https://api.github.com/repos/graalvm/truffle/pulls/comments/53161547"},"html":{"href":"https://github.com/graalvm/truffle/pull/40#discussion_r53161547"},"pull_request":{"href":"https://api.github.com/repos/graalvm/truffle/pulls/40"}}},"pull_request":{"url":"https://api.github.com/repos/graalvm/truffle/pulls/40","id":58551225,"html_url":"https://github.com/graalvm/truffle/pull/40","diff_url":"https://github.com/graalvm/truffle/pull/40.diff","patch_url":"https://github.com/graalvm/truffle/pull/40.patch","issue_url":"https://api.github.com/repos/graalvm/truffle/issues/40","number":40,"state":"open","locked":false,"title":"Add a DSL for generating layouts for the object model","user":{"login":"chrisseaton","id":341094,"avatar_url":"https://avatars.githubusercontent.com/u/341094?v=3","gravatar_id":"","url":"https://api.github.com/users/chrisseaton","html_url":"https://github.com/chrisseaton","followers_url":"https://api.github.com/users/chrisseaton/followers","following_url":"https://api.github.com/users/chrisseaton/following{/other_user}","gists_url":"https://api.github.com/users/chrisseaton/gists{/gist_id}","starred_url":"https://api.github.com/users/chrisseaton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chrisseaton/subscriptions","organizations_url":"https://api.github.com/users/chrisseaton/orgs","repos_url":"https://api.github.com/users/chrisseaton/repos","events_url":"https://api.github.com/users/chrisseaton/events{/privacy}","received_events_url":"https://api.github.com/users/chrisseaton/received_events","type":"User","site_admin":false},"body":"Ruby has a relatively Java-style class hierarchy, and many complex built-in classes which we implement in Java and need many fields to store state. The OM is more suited to simpler prototypical objects with few internal properties, so we found it a little verbose to use in JRuby. This DSL allows the declaration of Java-style classes, but backed using the OM. In JRuby this made it possible to move to an OM-only object style, where previously we had our own classes for internal fields and so two objects for every Ruby object (the OM object and the instance of our class).\r\n\r\nThis PR isn't ready for merge yet as the implementation of the generator is not yet high enough quality, but I'd like a review of the API and its semantics before I spend time refining the implementation, so please take a look at the `com.oracle.truffle.api.object.dsl` and `com.oracle.truffle.api.object.dsl.test` packages. Please ignore the implementation in the `com.oracle.truffle.api.object.dsl.generator` packages.\r\n\r\nThe API already works very well for JRuby.\r\n\r\n@chumer @jtulach please review for API, and @woess please check I'm using the OM correctly. Please don't merge (unless you're happy with the poor implementation of the generator).","created_at":"2016-02-07T17:16:40Z","updated_at":"2016-02-17T13:17:40Z","closed_at":null,"merged_at":null,"merge_commit_sha":"a240f1746cd14cfc9e6360d645095ca41542f2e9","assignee":{"login":"jtulach","id":1842422,"avatar_url":"https://avatars.githubusercontent.com/u/1842422?v=3","gravatar_id":"","url":"https://api.github.com/users/jtulach","html_url":"https://github.com/jtulach","followers_url":"https://api.github.com/users/jtulach/followers","following_url":"https://api.github.com/users/jtulach/following{/other_user}","gists_url":"https://api.github.com/users/jtulach/gists{/gist_id}","starred_url":"https://api.github.com/users/jtulach/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jtulach/subscriptions","organizations_url":"https://api.github.com/users/jtulach/orgs","repos_url":"https://api.github.com/users/jtulach/repos","events_url":"https://api.github.com/users/jtulach/events{/privacy}","received_events_url":"https://api.github.com/users/jtulach/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/graalvm/truffle/pulls/40/commits","review_comments_url":"https://api.github.com/repos/graalvm/truffle/pulls/40/comments","review_comment_url":"https://api.github.com/repos/graalvm/truffle/pulls/comments{/number}","comments_url":"https://api.github.com/repos/graalvm/truffle/issues/40/comments","statuses_url":"https://api.github.com/repos/graalvm/truffle/statuses/54d17532a5df5a4b01acd4ae3232bb2f577c18f9","head":{"label":"chrisseaton:om-dsl","ref":"om-dsl","sha":"54d17532a5df5a4b01acd4ae3232bb2f577c18f9","user":{"login":"chrisseaton","id":341094,"avatar_url":"https://avatars.githubusercontent.com/u/341094?v=3","gravatar_id":"","url":"https://api.github.com/users/chrisseaton","html_url":"https://github.com/chrisseaton","followers_url":"https://api.github.com/users/chrisseaton/followers","following_url":"https://api.github.com/users/chrisseaton/following{/other_user}","gists_url":"https://api.github.com/users/chrisseaton/gists{/gist_id}","starred_url":"https://api.github.com/users/chrisseaton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chrisseaton/subscriptions","organizations_url":"https://api.github.com/users/chrisseaton/orgs","repos_url":"https://api.github.com/users/chrisseaton/repos","events_url":"https://api.github.com/users/chrisseaton/events{/privacy}","received_events_url":"https://api.github.com/users/chrisseaton/received_events","type":"User","site_admin":false},"repo":{"id":50353986,"name":"truffle","full_name":"chrisseaton/truffle","owner":{"login":"chrisseaton","id":341094,"avatar_url":"https://avatars.githubusercontent.com/u/341094?v=3","gravatar_id":"","url":"https://api.github.com/users/chrisseaton","html_url":"https://github.com/chrisseaton","followers_url":"https://api.github.com/users/chrisseaton/followers","following_url":"https://api.github.com/users/chrisseaton/following{/other_user}","gists_url":"https://api.github.com/users/chrisseaton/gists{/gist_id}","starred_url":"https://api.github.com/users/chrisseaton/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chrisseaton/subscriptions","organizations_url":"https://api.github.com/users/chrisseaton/orgs","repos_url":"https://api.github.com/users/chrisseaton/repos","events_url":"https://api.github.com/users/chrisseaton/events{/privacy}","received_events_url":"https://api.github.com/users/chrisseaton/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/chrisseaton/truffle","description":"The Truffle Language Implementation Framework","fork":true,"url":"https://api.github.com/repos/chrisseaton/truffle","forks_url":"https://api.github.com/repos/chrisseaton/truffle/forks","keys_url":"https://api.github.com/repos/chrisseaton/truffle/keys{/key_id}","collaborators_url":"https://api.github.com/repos/chrisseaton/truffle/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/chrisseaton/truffle/teams","hooks_url":"https://api.github.com/repos/chrisseaton/truffle/hooks","issue_events_url":"https://api.github.com/repos/chrisseaton/truffle/issues/events{/number}","events_url":"https://api.github.com/repos/chrisseaton/truffle/events","assignees_url":"https://api.github.com/repos/chrisseaton/truffle/assignees{/user}","branches_url":"https://api.github.com/repos/chrisseaton/truffle/branches{/branch}","tags_url":"https://api.github.com/repos/chrisseaton/truffle/tags","blobs_url":"https://api.github.com/repos/chrisseaton/truffle/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/chrisseaton/truffle/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/chrisseaton/truffle/git/refs{/sha}","trees_url":"https://api.github.com/repos/chrisseaton/truffle/git/trees{/sha}","statuses_url":"https://api.github.com/repos/chrisseaton/truffle/statuses/{sha}","languages_url":"https://api.github.com/repos/chrisseaton/truffle/languages","stargazers_url":"https://api.github.com/repos/chrisseaton/truffle/stargazers","contributors_url":"https://api.github.com/repos/chrisseaton/truffle/contributors","subscribers_url":"https://api.github.com/repos/chrisseaton/truffle/subscribers","subscription_url":"https://api.github.com/repos/chrisseaton/truffle/subscription","commits_url":"https://api.github.com/repos/chrisseaton/truffle/commits{/sha}","git_commits_url":"https://api.github.com/repos/chrisseaton/truffle/git/commits{/sha}","comments_url":"https://api.github.com/repos/chrisseaton/truffle/comments{/number}","issue_comment_url":"https://api.github.com/repos/chrisseaton/truffle/issues/comments{/number}","contents_url":"https://api.github.com/repos/chrisseaton/truffle/contents/{+path}","compare_url":"https://api.github.com/repos/chrisseaton/truffle/compare/{base}...{head}","merges_url":"https://api.github.com/repos/chrisseaton/truffle/merges","archive_url":"https://api.github.com/repos/chrisseaton/truffle/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/chrisseaton/truffle/downloads","issues_url":"https://api.github.com/repos/chrisseaton/truffle/issues{/number}","pulls_url":"https://api.github.com/repos/chrisseaton/truffle/pulls{/number}","milestones_url":"https://api.github.com/repos/chrisseaton/truffle/milestones{/number}","notifications_url":"https://api.github.com/repos/chrisseaton/truffle/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/chrisseaton/truffle/labels{/name}","releases_url":"https://api.github.com/repos/chrisseaton/truffle/releases{/id}","deployments_url":"https://api.github.com/repos/chrisseaton/truffle/deployments","created_at":"2016-01-25T14:00:09Z","updated_at":"2016-01-25T14:00:13Z","pushed_at":"2016-02-17T01:31:37Z","git_url":"git://github.com/chrisseaton/truffle.git","ssh_url":"git@github.com:chrisseaton/truffle.git","clone_url":"https://github.com/chrisseaton/truffle.git","svn_url":"https://github.com/chrisseaton/truffle","homepage":"","size":44117,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"graalvm:master","ref":"master","sha":"831c1bb752dfdf98967bc1d45b0b17cd1c05f18d","user":{"login":"graalvm","id":10176827,"avatar_url":"https://avatars.githubusercontent.com/u/10176827?v=3","gravatar_id":"","url":"https://api.github.com/users/graalvm","html_url":"https://github.com/graalvm","followers_url":"https://api.github.com/users/graalvm/followers","following_url":"https://api.github.com/users/graalvm/following{/other_user}","gists_url":"https://api.github.com/users/graalvm/gists{/gist_id}","starred_url":"https://api.github.com/users/graalvm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/graalvm/subscriptions","organizations_url":"https://api.github.com/users/graalvm/orgs","repos_url":"https://api.github.com/users/graalvm/repos","events_url":"https://api.github.com/users/graalvm/events{/privacy}","received_events_url":"https://api.github.com/users/graalvm/received_events","type":"Organization","site_admin":false},"repo":{"id":49662222,"name":"truffle","full_name":"graalvm/truffle","owner":{"login":"graalvm","id":10176827,"avatar_url":"https://avatars.githubusercontent.com/u/10176827?v=3","gravatar_id":"","url":"https://api.github.com/users/graalvm","html_url":"https://github.com/graalvm","followers_url":"https://api.github.com/users/graalvm/followers","following_url":"https://api.github.com/users/graalvm/following{/other_user}","gists_url":"https://api.github.com/users/graalvm/gists{/gist_id}","starred_url":"https://api.github.com/users/graalvm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/graalvm/subscriptions","organizations_url":"https://api.github.com/users/graalvm/orgs","repos_url":"https://api.github.com/users/graalvm/repos","events_url":"https://api.github.com/users/graalvm/events{/privacy}","received_events_url":"https://api.github.com/users/graalvm/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/graalvm/truffle","description":"The Truffle Language Implementation Framework","fork":false,"url":"https://api.github.com/repos/graalvm/truffle","forks_url":"https://api.github.com/repos/graalvm/truffle/forks","keys_url":"https://api.github.com/repos/graalvm/truffle/keys{/key_id}","collaborators_url":"https://api.github.com/repos/graalvm/truffle/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/graalvm/truffle/teams","hooks_url":"https://api.github.com/repos/graalvm/truffle/hooks","issue_events_url":"https://api.github.com/repos/graalvm/truffle/issues/events{/number}","events_url":"https://api.github.com/repos/graalvm/truffle/events","assignees_url":"https://api.github.com/repos/graalvm/truffle/assignees{/user}","branches_url":"https://api.github.com/repos/graalvm/truffle/branches{/branch}","tags_url":"https://api.github.com/repos/graalvm/truffle/tags","blobs_url":"https://api.github.com/repos/graalvm/truffle/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/graalvm/truffle/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/graalvm/truffle/git/refs{/sha}","trees_url":"https://api.github.com/repos/graalvm/truffle/git/trees{/sha}","statuses_url":"https://api.github.com/repos/graalvm/truffle/statuses/{sha}","languages_url":"https://api.github.com/repos/graalvm/truffle/languages","stargazers_url":"https://api.github.com/repos/graalvm/truffle/stargazers","contributors_url":"https://api.github.com/repos/graalvm/truffle/contributors","subscribers_url":"https://api.github.com/repos/graalvm/truffle/subscribers","subscription_url":"https://api.github.com/repos/graalvm/truffle/subscription","commits_url":"https://api.github.com/repos/graalvm/truffle/commits{/sha}","git_commits_url":"https://api.github.com/repos/graalvm/truffle/git/commits{/sha}","comments_url":"https://api.github.com/repos/graalvm/truffle/comments{/number}","issue_comment_url":"https://api.github.com/repos/graalvm/truffle/issues/comments{/number}","contents_url":"https://api.github.com/repos/graalvm/truffle/contents/{+path}","compare_url":"https://api.github.com/repos/graalvm/truffle/compare/{base}...{head}","merges_url":"https://api.github.com/repos/graalvm/truffle/merges","archive_url":"https://api.github.com/repos/graalvm/truffle/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/graalvm/truffle/downloads","issues_url":"https://api.github.com/repos/graalvm/truffle/issues{/number}","pulls_url":"https://api.github.com/repos/graalvm/truffle/pulls{/number}","milestones_url":"https://api.github.com/repos/graalvm/truffle/milestones{/number}","notifications_url":"https://api.github.com/repos/graalvm/truffle/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/graalvm/truffle/labels{/name}","releases_url":"https://api.github.com/repos/graalvm/truffle/releases{/id}","deployments_url":"https://api.github.com/repos/graalvm/truffle/deployments","created_at":"2016-01-14T17:11:35Z","updated_at":"2016-02-14T22:32:00Z","pushed_at":"2016-02-17T12:22:53Z","git_url":"git://github.com/graalvm/truffle.git","ssh_url":"git@github.com:graalvm/truffle.git","clone_url":"https://github.com/graalvm/truffle.git","svn_url":"https://github.com/graalvm/truffle","homepage":"","size":20179,"stargazers_count":25,"watchers_count":25,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":15,"mirror_url":null,"open_issues_count":13,"forks":15,"open_issues":13,"watchers":25,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/graalvm/truffle/pulls/40"},"html":{"href":"https://github.com/graalvm/truffle/pull/40"},"issue":{"href":"https://api.github.com/repos/graalvm/truffle/issues/40"},"comments":{"href":"https://api.github.com/repos/graalvm/truffle/issues/40/comments"},"review_comments":{"href":"https://api.github.com/repos/graalvm/truffle/pulls/40/comments"},"review_comment":{"href":"https://api.github.com/repos/graalvm/truffle/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/graalvm/truffle/pulls/40/commits"},"statuses":{"href":"https://api.github.com/repos/graalvm/truffle/statuses/54d17532a5df5a4b01acd4ae3232bb2f577c18f9"}}}}