{"action":"created","comment":{"url":"https://api.github.com/repos/kaleidicassociates/autowrap/pulls/comments/235272889","pull_request_review_id":177099832,"id":235272889,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzNTI3Mjg4OQ==","diff_hunk":"@@ -0,0 +1,1061 @@\n+module autowrap.csharp.csharp;\n+\n+import autowrap.csharp.boilerplate;\n+import autowrap.csharp.common;\n+import autowrap.reflection;\n+\n+import std.ascii;\n+import std.datetime;\n+import std.traits;\n+import std.string;\n+import std.uuid;\n+\n+import std.stdio;\n+\n+private __gshared string[string] returnTypes;\n+private __gshared csharpNamespace[string] namespaces;\n+private __gshared csharpRange rangeDef;\n+\n+enum string voidTypeString = \"void\";\n+enum string stringTypeString = \"string\";\n+enum string wstringTypeString = \"wstring\";\n+enum string dstringTypeString = \"dstring\";\n+enum string boolTypeString = \"bool\";\n+enum string dateTimeTypeString = \"DateTime\";\n+enum string sysTimeTypeString = \"SysTime\";\n+enum string uuidTypeString = \"UUID\";\n+enum string charTypeString = \"char\";\n+enum string wcharTypeString = \"wchar\";\n+enum string dcharTypeString = \"dchar\";\n+enum string ubyteTypeString = \"ubyte\";\n+enum string byteTypeString = \"byte\";\n+enum string ushortTypeString = \"ushort\";\n+enum string shortTypeString = \"short\";\n+enum string uintTypeString = \"uint\";\n+enum string intTypeString = \"int\";\n+enum string ulongTypeString = \"ulong\";\n+enum string longTypeString = \"long\";\n+enum string floatTypeString = \"float\";\n+enum string doubleTypeString = \"double\";\n+enum string sliceTypeString = \"slice\";\n+\n+private class csharpNamespace {\n+    public string namespace;\n+    public string functions;\n+    public csharpAggregate[string] aggregates;\n+\n+    public this(string ns) {\n+        namespace = ns;\n+        functions = string.init;\n+    }\n+\n+    public override string toString() {\n+        char[] ret;\n+        ret.reserve(1_048_576);\n+        foreach(csns; namespaces.byValue()) {\n+            ret ~= \"namespace \" ~ csns.namespace ~ \" {\" ~newline;\n+            ret ~= \"    using System;\" ~ newline;\n+            ret ~= \"    using System.Collections.Generic;\" ~ newline;\n+            ret ~= \"    using System.Linq;\" ~ newline;\n+            ret ~= \"    using System.Reflection;\" ~ newline;\n+            ret ~= \"    using System.Runtime.InteropServices;\" ~ newline;\n+            ret ~= \"    using Autowrap;\" ~ newline ~ newline;\n+            ret ~= \"    public static class Functions {\" ~ newline;\n+            ret ~= csns.functions;\n+            ret ~= \"    }\" ~ newline ~ newline;\n+            foreach(agg; aggregates.byValue()) {\n+                ret ~= agg.toString();\n+            }\n+            ret ~= \"}\" ~ newline;\n+        }\n+        return cast(immutable)ret;\n+    }\n+}\n+\n+private class csharpAggregate {\n+    public string name;\n+    public bool isStruct;\n+    public string constructors;\n+    public string functions;\n+    public string methods;\n+    public string properties;\n+\n+    public this (string name, bool isStruct) {\n+        this.name = name;\n+        this.isStruct = isStruct;\n+        this.constructors = string.init;\n+        this.functions = string.init;\n+        this.methods = string.init;\n+        this.properties = string.init;\n+    }\n+\n+    public override string toString() {\n+        char[] ret;\n+        ret.reserve(32_768);\n+        if (isStruct) {\n+            ret ~= \"    [StructLayout(LayoutKind.Sequential)]\" ~ newline;\n+            ret ~= \"    public struct \" ~ camelToPascalCase(this.name) ~ \" {\" ~ newline;\n+        } else {\n+            ret ~= \"    public class \" ~ camelToPascalCase(this.name) ~ \" : DLangObject {\" ~ newline;\n+        }\n+        if (functions != string.init) ret ~= functions ~ newline;\n+        if (constructors != string.init) ret ~= constructors ~ newline;\n+        if (methods != string.init) ret ~= methods ~ newline;\n+        if (properties != string.init) ret ~= properties;\n+        ret ~= \"    }\" ~ newline ~ newline;\n+        return cast(immutable)ret;\n+    }\n+}\n+\n+public struct csharpRange {\n+    public string constructors = string.init;\n+    public string enumerators = string.init;\n+    public string functions = string.init;\n+    public string getters = string.init;\n+    public string setters = string.init; \n+    public string appendValues = string.init;\n+    public string appendArrays = string.init;\n+    public string sliceEnd = string.init;\n+    public string sliceRange = string.init;\n+\n+    public string toString() {\n+        char[] ret;\n+        ret.reserve(32_768);\n+        ret ~= \"    internal class RangeFunctions {\" ~ newline;","path":"csharp/source/autowrap/csharp/csharp.d","position":null,"original_position":124,"commit_id":"918c18f3047a87b1009ea1e22e25e03ba45999c5","original_commit_id":"6af2b50e6be07e540c6f9a68c9a08b3179fa9439","user":{"login":"LightBender","id":1262302,"node_id":"MDQ6VXNlcjEyNjIzMDI=","avatar_url":"https://avatars0.githubusercontent.com/u/1262302?v=4","gravatar_id":"","url":"https://api.github.com/users/LightBender","html_url":"https://github.com/LightBender","followers_url":"https://api.github.com/users/LightBender/followers","following_url":"https://api.github.com/users/LightBender/following{/other_user}","gists_url":"https://api.github.com/users/LightBender/gists{/gist_id}","starred_url":"https://api.github.com/users/LightBender/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LightBender/subscriptions","organizations_url":"https://api.github.com/users/LightBender/orgs","repos_url":"https://api.github.com/users/LightBender/repos","events_url":"https://api.github.com/users/LightBender/events{/privacy}","received_events_url":"https://api.github.com/users/LightBender/received_events","type":"User","site_admin":false},"body":".join throws an error when used on a char[] with a string. Also, what is join doing that ~ isn't?","created_at":"2018-11-21T07:11:22Z","updated_at":"2018-11-21T07:11:22Z","html_url":"https://github.com/kaleidicassociates/autowrap/pull/20#discussion_r235272889","pull_request_url":"https://api.github.com/repos/kaleidicassociates/autowrap/pulls/20","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/kaleidicassociates/autowrap/pulls/comments/235272889"},"html":{"href":"https://github.com/kaleidicassociates/autowrap/pull/20#discussion_r235272889"},"pull_request":{"href":"https://api.github.com/repos/kaleidicassociates/autowrap/pulls/20"}},"in_reply_to_id":233066676},"pull_request":{"url":"https://api.github.com/repos/kaleidicassociates/autowrap/pulls/20","id":230462747,"node_id":"MDExOlB1bGxSZXF1ZXN0MjMwNDYyNzQ3","html_url":"https://github.com/kaleidicassociates/autowrap/pull/20","diff_url":"https://github.com/kaleidicassociates/autowrap/pull/20.diff","patch_url":"https://github.com/kaleidicassociates/autowrap/pull/20.patch","issue_url":"https://api.github.com/repos/kaleidicassociates/autowrap/issues/20","number":20,"state":"open","locked":false,"title":"Add Initial C# Support","user":{"login":"LightBender","id":1262302,"node_id":"MDQ6VXNlcjEyNjIzMDI=","avatar_url":"https://avatars0.githubusercontent.com/u/1262302?v=4","gravatar_id":"","url":"https://api.github.com/users/LightBender","html_url":"https://github.com/LightBender","followers_url":"https://api.github.com/users/LightBender/followers","following_url":"https://api.github.com/users/LightBender/following{/other_user}","gists_url":"https://api.github.com/users/LightBender/gists{/gist_id}","starred_url":"https://api.github.com/users/LightBender/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LightBender/subscriptions","organizations_url":"https://api.github.com/users/LightBender/orgs","repos_url":"https://api.github.com/users/LightBender/repos","events_url":"https://api.github.com/users/LightBender/events{/privacy}","received_events_url":"https://api.github.com/users/LightBender/received_events","type":"User","site_admin":false},"body":"This PR adds support for C# wrapper code-generation of the following:\r\nFunctions\r\nStructs\r\nClasses\r\nInitial Range Support","created_at":"2018-11-13T12:47:50Z","updated_at":"2018-11-21T07:11:22Z","closed_at":null,"merged_at":null,"merge_commit_sha":"6e2bca8f71a2f29f338709ce8f53584b2ce3ef4f","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/kaleidicassociates/autowrap/pulls/20/commits","review_comments_url":"https://api.github.com/repos/kaleidicassociates/autowrap/pulls/20/comments","review_comment_url":"https://api.github.com/repos/kaleidicassociates/autowrap/pulls/comments{/number}","comments_url":"https://api.github.com/repos/kaleidicassociates/autowrap/issues/20/comments","statuses_url":"https://api.github.com/repos/kaleidicassociates/autowrap/statuses/918c18f3047a87b1009ea1e22e25e03ba45999c5","head":{"label":"LightBender:csharp","ref":"csharp","sha":"918c18f3047a87b1009ea1e22e25e03ba45999c5","user":{"login":"LightBender","id":1262302,"node_id":"MDQ6VXNlcjEyNjIzMDI=","avatar_url":"https://avatars0.githubusercontent.com/u/1262302?v=4","gravatar_id":"","url":"https://api.github.com/users/LightBender","html_url":"https://github.com/LightBender","followers_url":"https://api.github.com/users/LightBender/followers","following_url":"https://api.github.com/users/LightBender/following{/other_user}","gists_url":"https://api.github.com/users/LightBender/gists{/gist_id}","starred_url":"https://api.github.com/users/LightBender/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LightBender/subscriptions","organizations_url":"https://api.github.com/users/LightBender/orgs","repos_url":"https://api.github.com/users/LightBender/repos","events_url":"https://api.github.com/users/LightBender/events{/privacy}","received_events_url":"https://api.github.com/users/LightBender/received_events","type":"User","site_admin":false},"repo":{"id":145404499,"node_id":"MDEwOlJlcG9zaXRvcnkxNDU0MDQ0OTk=","name":"autowrap","full_name":"LightBender/autowrap","private":false,"owner":{"login":"LightBender","id":1262302,"node_id":"MDQ6VXNlcjEyNjIzMDI=","avatar_url":"https://avatars0.githubusercontent.com/u/1262302?v=4","gravatar_id":"","url":"https://api.github.com/users/LightBender","html_url":"https://github.com/LightBender","followers_url":"https://api.github.com/users/LightBender/followers","following_url":"https://api.github.com/users/LightBender/following{/other_user}","gists_url":"https://api.github.com/users/LightBender/gists{/gist_id}","starred_url":"https://api.github.com/users/LightBender/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LightBender/subscriptions","organizations_url":"https://api.github.com/users/LightBender/orgs","repos_url":"https://api.github.com/users/LightBender/repos","events_url":"https://api.github.com/users/LightBender/events{/privacy}","received_events_url":"https://api.github.com/users/LightBender/received_events","type":"User","site_admin":false},"html_url":"https://github.com/LightBender/autowrap","description":"Wrap existing D code for use in other environments such as Python and Excel","fork":true,"url":"https://api.github.com/repos/LightBender/autowrap","forks_url":"https://api.github.com/repos/LightBender/autowrap/forks","keys_url":"https://api.github.com/repos/LightBender/autowrap/keys{/key_id}","collaborators_url":"https://api.github.com/repos/LightBender/autowrap/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/LightBender/autowrap/teams","hooks_url":"https://api.github.com/repos/LightBender/autowrap/hooks","issue_events_url":"https://api.github.com/repos/LightBender/autowrap/issues/events{/number}","events_url":"https://api.github.com/repos/LightBender/autowrap/events","assignees_url":"https://api.github.com/repos/LightBender/autowrap/assignees{/user}","branches_url":"https://api.github.com/repos/LightBender/autowrap/branches{/branch}","tags_url":"https://api.github.com/repos/LightBender/autowrap/tags","blobs_url":"https://api.github.com/repos/LightBender/autowrap/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/LightBender/autowrap/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/LightBender/autowrap/git/refs{/sha}","trees_url":"https://api.github.com/repos/LightBender/autowrap/git/trees{/sha}","statuses_url":"https://api.github.com/repos/LightBender/autowrap/statuses/{sha}","languages_url":"https://api.github.com/repos/LightBender/autowrap/languages","stargazers_url":"https://api.github.com/repos/LightBender/autowrap/stargazers","contributors_url":"https://api.github.com/repos/LightBender/autowrap/contributors","subscribers_url":"https://api.github.com/repos/LightBender/autowrap/subscribers","subscription_url":"https://api.github.com/repos/LightBender/autowrap/subscription","commits_url":"https://api.github.com/repos/LightBender/autowrap/commits{/sha}","git_commits_url":"https://api.github.com/repos/LightBender/autowrap/git/commits{/sha}","comments_url":"https://api.github.com/repos/LightBender/autowrap/comments{/number}","issue_comment_url":"https://api.github.com/repos/LightBender/autowrap/issues/comments{/number}","contents_url":"https://api.github.com/repos/LightBender/autowrap/contents/{+path}","compare_url":"https://api.github.com/repos/LightBender/autowrap/compare/{base}...{head}","merges_url":"https://api.github.com/repos/LightBender/autowrap/merges","archive_url":"https://api.github.com/repos/LightBender/autowrap/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/LightBender/autowrap/downloads","issues_url":"https://api.github.com/repos/LightBender/autowrap/issues{/number}","pulls_url":"https://api.github.com/repos/LightBender/autowrap/pulls{/number}","milestones_url":"https://api.github.com/repos/LightBender/autowrap/milestones{/number}","notifications_url":"https://api.github.com/repos/LightBender/autowrap/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/LightBender/autowrap/labels{/name}","releases_url":"https://api.github.com/repos/LightBender/autowrap/releases{/id}","deployments_url":"https://api.github.com/repos/LightBender/autowrap/deployments","created_at":"2018-08-20T10:45:37Z","updated_at":"2018-08-23T20:49:22Z","pushed_at":"2018-11-21T06:43:39Z","git_url":"git://github.com/LightBender/autowrap.git","ssh_url":"git@github.com:LightBender/autowrap.git","clone_url":"https://github.com/LightBender/autowrap.git","svn_url":"https://github.com/LightBender/autowrap","homepage":null,"size":1714,"stargazers_count":0,"watchers_count":0,"language":"D","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"bsd-3-clause","name":"BSD 3-Clause \"New\" or \"Revised\" License","spdx_id":"BSD-3-Clause","url":"https://api.github.com/licenses/bsd-3-clause","node_id":"MDc6TGljZW5zZTU="},"forks":1,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"kaleidicassociates:master","ref":"master","sha":"25c308624f1d1403a7938909fe7dae850526b493","user":{"login":"kaleidicassociates","id":15332810,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE1MzMyODEw","avatar_url":"https://avatars0.githubusercontent.com/u/15332810?v=4","gravatar_id":"","url":"https://api.github.com/users/kaleidicassociates","html_url":"https://github.com/kaleidicassociates","followers_url":"https://api.github.com/users/kaleidicassociates/followers","following_url":"https://api.github.com/users/kaleidicassociates/following{/other_user}","gists_url":"https://api.github.com/users/kaleidicassociates/gists{/gist_id}","starred_url":"https://api.github.com/users/kaleidicassociates/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kaleidicassociates/subscriptions","organizations_url":"https://api.github.com/users/kaleidicassociates/orgs","repos_url":"https://api.github.com/users/kaleidicassociates/repos","events_url":"https://api.github.com/users/kaleidicassociates/events{/privacy}","received_events_url":"https://api.github.com/users/kaleidicassociates/received_events","type":"Organization","site_admin":false},"repo":{"id":130044944,"node_id":"MDEwOlJlcG9zaXRvcnkxMzAwNDQ5NDQ=","name":"autowrap","full_name":"kaleidicassociates/autowrap","private":false,"owner":{"login":"kaleidicassociates","id":15332810,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE1MzMyODEw","avatar_url":"https://avatars0.githubusercontent.com/u/15332810?v=4","gravatar_id":"","url":"https://api.github.com/users/kaleidicassociates","html_url":"https://github.com/kaleidicassociates","followers_url":"https://api.github.com/users/kaleidicassociates/followers","following_url":"https://api.github.com/users/kaleidicassociates/following{/other_user}","gists_url":"https://api.github.com/users/kaleidicassociates/gists{/gist_id}","starred_url":"https://api.github.com/users/kaleidicassociates/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kaleidicassociates/subscriptions","organizations_url":"https://api.github.com/users/kaleidicassociates/orgs","repos_url":"https://api.github.com/users/kaleidicassociates/repos","events_url":"https://api.github.com/users/kaleidicassociates/events{/privacy}","received_events_url":"https://api.github.com/users/kaleidicassociates/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/kaleidicassociates/autowrap","description":"Wrap existing D code for use in other environments such as Python and Excel","fork":false,"url":"https://api.github.com/repos/kaleidicassociates/autowrap","forks_url":"https://api.github.com/repos/kaleidicassociates/autowrap/forks","keys_url":"https://api.github.com/repos/kaleidicassociates/autowrap/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kaleidicassociates/autowrap/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kaleidicassociates/autowrap/teams","hooks_url":"https://api.github.com/repos/kaleidicassociates/autowrap/hooks","issue_events_url":"https://api.github.com/repos/kaleidicassociates/autowrap/issues/events{/number}","events_url":"https://api.github.com/repos/kaleidicassociates/autowrap/events","assignees_url":"https://api.github.com/repos/kaleidicassociates/autowrap/assignees{/user}","branches_url":"https://api.github.com/repos/kaleidicassociates/autowrap/branches{/branch}","tags_url":"https://api.github.com/repos/kaleidicassociates/autowrap/tags","blobs_url":"https://api.github.com/repos/kaleidicassociates/autowrap/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kaleidicassociates/autowrap/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kaleidicassociates/autowrap/git/refs{/sha}","trees_url":"https://api.github.com/repos/kaleidicassociates/autowrap/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kaleidicassociates/autowrap/statuses/{sha}","languages_url":"https://api.github.com/repos/kaleidicassociates/autowrap/languages","stargazers_url":"https://api.github.com/repos/kaleidicassociates/autowrap/stargazers","contributors_url":"https://api.github.com/repos/kaleidicassociates/autowrap/contributors","subscribers_url":"https://api.github.com/repos/kaleidicassociates/autowrap/subscribers","subscription_url":"https://api.github.com/repos/kaleidicassociates/autowrap/subscription","commits_url":"https://api.github.com/repos/kaleidicassociates/autowrap/commits{/sha}","git_commits_url":"https://api.github.com/repos/kaleidicassociates/autowrap/git/commits{/sha}","comments_url":"https://api.github.com/repos/kaleidicassociates/autowrap/comments{/number}","issue_comment_url":"https://api.github.com/repos/kaleidicassociates/autowrap/issues/comments{/number}","contents_url":"https://api.github.com/repos/kaleidicassociates/autowrap/contents/{+path}","compare_url":"https://api.github.com/repos/kaleidicassociates/autowrap/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kaleidicassociates/autowrap/merges","archive_url":"https://api.github.com/repos/kaleidicassociates/autowrap/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kaleidicassociates/autowrap/downloads","issues_url":"https://api.github.com/repos/kaleidicassociates/autowrap/issues{/number}","pulls_url":"https://api.github.com/repos/kaleidicassociates/autowrap/pulls{/number}","milestones_url":"https://api.github.com/repos/kaleidicassociates/autowrap/milestones{/number}","notifications_url":"https://api.github.com/repos/kaleidicassociates/autowrap/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kaleidicassociates/autowrap/labels{/name}","releases_url":"https://api.github.com/repos/kaleidicassociates/autowrap/releases{/id}","deployments_url":"https://api.github.com/repos/kaleidicassociates/autowrap/deployments","created_at":"2018-04-18T10:21:11Z","updated_at":"2018-11-01T11:13:43Z","pushed_at":"2018-11-21T06:43:40Z","git_url":"git://github.com/kaleidicassociates/autowrap.git","ssh_url":"git@github.com:kaleidicassociates/autowrap.git","clone_url":"https://github.com/kaleidicassociates/autowrap.git","svn_url":"https://github.com/kaleidicassociates/autowrap","homepage":null,"size":544,"stargazers_count":13,"watchers_count":13,"language":"D","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"archived":false,"open_issues_count":4,"license":{"key":"bsd-3-clause","name":"BSD 3-Clause \"New\" or \"Revised\" License","spdx_id":"BSD-3-Clause","url":"https://api.github.com/licenses/bsd-3-clause","node_id":"MDc6TGljZW5zZTU="},"forks":4,"open_issues":4,"watchers":13,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/kaleidicassociates/autowrap/pulls/20"},"html":{"href":"https://github.com/kaleidicassociates/autowrap/pull/20"},"issue":{"href":"https://api.github.com/repos/kaleidicassociates/autowrap/issues/20"},"comments":{"href":"https://api.github.com/repos/kaleidicassociates/autowrap/issues/20/comments"},"review_comments":{"href":"https://api.github.com/repos/kaleidicassociates/autowrap/pulls/20/comments"},"review_comment":{"href":"https://api.github.com/repos/kaleidicassociates/autowrap/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/kaleidicassociates/autowrap/pulls/20/commits"},"statuses":{"href":"https://api.github.com/repos/kaleidicassociates/autowrap/statuses/918c18f3047a87b1009ea1e22e25e03ba45999c5"}},"author_association":"NONE"}}
{"actor":{"display_login":"LightBender"}}