{"action":"created","comment":{"url":"https://api.github.com/repos/D-Programming-Language/dmd/pulls/comments/31882863","id":31882863,"diff_hunk":"@@ -21,18 +21,376 @@\n #include \"mtype.h\"\n #include \"declaration.h\"\n #include \"tokens.h\"\n+#include \"enum.h\"\n+#include \"template.h\"\n+#include \"arraytypes.h\"\n+#include \"expression.h\"\n \n-Expression *resolveAliasThis(Scope *sc, Expression *e)\n+typedef Array<const char *> Strings;\n+\n+/**\n+ * iterateAliasThis resolves alias this subtypes for `e` and applies it to `dg`.\n+ * dg should return true, if appropriate subtype has been found. Otherwise it should returns 0.\n+ * Also dg can get context through secong parameter `ctx`, which was passed through fourth argument of iterateAliasThis.\n+ * `dg` can return result expression through `outexpr` parameter, and if it is not NULL, it will be pushed to `ret` array.\n+ * At the first stage iterateAliasThis iterates direct \"alias this\"-es and pushes non-null `outexpr`-es to `ret`.\n+ * If `dg` for one of direct \"alias this\"-es returns true then `iterateAliasThis` breaks at this stage and returns true\n+ * through return value and returned by `dg` expression array through `ret`.\n+ * Even if true returned by first `dg` call, remaining direct \"alias this\"-es will be processed.\n+ *\n+ * If neither of the direct aliases did not return true iterateAliasThis is recursive applied to direct aliases and base\n+ * classes and interfaces.\n+ * If one of those `iterateAliasThis` calls returns true our `iterateAliasThis` will return true. Otherwise it will return 0.\n+ *\n+ * The the last argument needs for internal use and should be NULL in user call.\n+ */\n+\n+bool iterateAliasThis(Scope *sc, Expression *e, IterateAliasThisDg dg,\n+                      void *ctx, Expressions *ret, bool gagerrors, StringTable *directtypes)\n+{\n+    //printf(\"iterateAliasThis: %s\\n\", e->toChars());\n+\n+    Dsymbols *aliasThisSymbols = NULL;\n+    if (e->type->toBasetype()->ty == Tstruct)\n+    {\n+        TypeStruct *ts = (TypeStruct *)e->type->toBasetype();\n+        aliasThisSymbols = ts->sym->aliasThisSymbols;\n+    }\n+    else if (e->type->toBasetype()->ty == Tclass)\n+    {\n+        TypeClass *ts = (TypeClass *)e->type->toBasetype();\n+        if (ts->sym->aliasThisSymbols)\n+        {\n+            aliasThisSymbols = ts->sym->aliasThisSymbols;\n+        }\n+    }\n+    else\n+    {\n+        return 0;\n+    }\n+\n+    if (!directtypes)\n+    {\n+        directtypes = new StringTable();\n+        directtypes->_init();\n+    }\n+    StringValue *depth_counter = directtypes->lookup(e->type->deco, strlen(e->type->deco));\n+    if (!depth_counter)\n+    {\n+        depth_counter = directtypes->insert(e->type->deco, strlen(e->type->deco));\n+        depth_counter->ptrvalue = (void*)e;\n+    }\n+    else if (depth_counter->ptrvalue)\n+    {\n+        return false; //This type already was visited.\n+    }\n+    else\n+    {\n+        depth_counter->ptrvalue = (void*)e;\n+    }\n+\n+    bool r = false;\n+\n+    if (aliasThisSymbols)\n+    {\n+        for (int i = 0; i < aliasThisSymbols->dim; ++i)\n+        {\n+            unsigned olderrors = 0;\n+            if (gagerrors)\n+                olderrors = global.startGagging();\n+            Expression *e1 = resolveAliasThis(sc, e, i);\n+\n+            if(gagerrors && global.endGagging(olderrors))\n+                continue;\n+            if (e1->type->ty == Terror)\n+                continue;\n+            assert(e1->type->deco);\n+\n+            Expression *e2 = NULL;\n+            int success = dg(sc, e1, ctx, &e2);\n+            r = r || success;\n+\n+            if (e2)\n+            {\n+                ret->push(e2);\n+            }\n+\n+            if (!success)\n+            {\n+                r = iterateAliasThis(sc, e1, dg, ctx, ret, gagerrors, directtypes) || r;\n+            }\n+        }\n+    }\n+\n+    if (e->type->ty == Tclass)\n+    {\n+        ClassDeclaration *cd = ((TypeClass *)e->type)->sym;\n+        assert(cd->baseclasses);\n+        for (int i = 0; i < cd->baseclasses->dim; ++i)\n+        {\n+            ClassDeclaration *bd = (*cd->baseclasses)[i]->base;\n+            Type *bt = bd->type;\n+            Expression *e1 = e->castTo(sc, bt);\n+            r = iterateAliasThis(sc, e1, dg, ctx, ret, gagerrors, directtypes) || r;\n+        }\n+    }\n+\n+    depth_counter->ptrvalue = NULL;\n+    return r;\n+}\n+\n+Type *aliasThisOf(Type *t, int idx, bool *islvalue = NULL)\n+{\n+    bool dummy;\n+    if (!islvalue)\n+        islvalue = &dummy;\n+    *islvalue = false;\n+    AggregateDeclaration *ad = isAggregate(t);\n+    if (ad && ad->aliasThisSymbols && ad->aliasThisSymbols->dim > idx)\n+    {\n+        Dsymbol *s = (*ad->aliasThisSymbols)[idx];\n+        if (s->isAliasDeclaration())\n+            s = s->toAlias();\n+        Declaration *d = s->isDeclaration();\n+        if (d && !d->isTupleDeclaration())\n+        {\n+            assert(d->type);\n+            Type *t2 = d->type;\n+            if (d->isVarDeclaration() && d->needThis())\n+            {\n+                t2 = t2->addMod(t->mod);\n+                *islvalue = true; //Variable is always l-value\n+            }\n+            else if (d->isFuncDeclaration())\n+            {\n+                FuncDeclaration *fd = resolveFuncCall(Loc(), NULL, d, NULL, t, NULL, 1);\n+                if (fd && fd->errors)\n+                    return Type::terror;\n+                if (fd && !fd->type->nextOf() && !fd->functionSemantic())\n+                    fd = NULL;\n+                if (fd)\n+                {\n+                    t2 = fd->type->nextOf();\n+                    if (!t2) // issue 14185\n+                        return Type::terror;\n+                    t2 = t2->substWildTo(t->mod == 0 ? MODmutable : t->mod);\n+                    if (((TypeFunction *)fd->type)->isref)\n+                        *islvalue = true;\n+                }\n+                else\n+                    return Type::terror;\n+            }\n+            return t2;\n+        }\n+        EnumDeclaration *ed = s->isEnumDeclaration();\n+        if (ed)\n+        {\n+            Type *t2 = ed->type;\n+            return t2;\n+        }\n+        TemplateDeclaration *td = s->isTemplateDeclaration();\n+        if (td)\n+        {\n+            assert(td->scope);\n+            FuncDeclaration *fd = resolveFuncCall(Loc(), NULL, td, NULL, t, NULL, 1);\n+            if (fd && fd->errors)\n+                return Type::terror;\n+            if (fd && fd->functionSemantic())\n+            {\n+                Type *t2 = fd->type->nextOf();\n+                t2 = t2->substWildTo(t->mod == 0 ? MODmutable : t->mod);\n+                if (((TypeFunction *)fd->type)->isref)\n+                    *islvalue = true;\n+                return t2;\n+            }\n+            else\n+                return Type::terror;\n+        }\n+        //printf(\"%s\\n\", s->kind());\n+    }\n+    return NULL;\n+}\n+\n+/**\n+    This function walk over `from` basetype tree and search types,\n+    which can be converted (without alias this subtyping) to `to`.\n+    If there are many ways to convert `from` to `to`, this function\n+    raises an error and prints all those ways.\n+    To prevent infinity loop in types with circular subtyping,\n+    pattern \"check a flag, lock a flag, do work is a flag wasn't locked, return flag back\" is used.\n+*/\n+MATCH implicitConvToWithAliasThis(Loc loc, Type *from, Type *to, Type *root_from, OutBuffer *buff,\n+                                  int *state, OutBuffer *matchname)\n+{\n+    //printf(\"implicitConvToWithAliasThis, %s -> %s\\n\", from->toChars(), to->toChars());\n+    if (from->aliasthislock & RECtracing)\n+        return MATCHnomatch;\n+\n+    unsigned oldatlock = from->aliasthislock;\n+    from->aliasthislock |= RECtracing;\n+    if (!buff)\n+    {\n+        buff = new OutBuffer();\n+        buff->writestring(from->toChars());\n+    }\n+    int st = 0; //0 - no match\n+                //1 - match\n+                //2 - many matches\n+    if (!state)\n+        state = &st;\n+\n+    if (!matchname)\n+    {\n+        matchname = new OutBuffer();\n+    }\n+\n+    if (!root_from)\n+    {\n+        root_from = from;\n+    }\n+    int a_count = 0;\n+    AggregateDeclaration *ad = isAggregate(from);\n+    if (!ad)\n+        return MATCHnomatch;\n+    AggregateDeclaration *err_ad = isAggregate(root_from);\n+    assert(err_ad);\n+    if (ad && ad->aliasThisSymbols)\n+        a_count = (int)ad->aliasThisSymbols->dim;\n+\n+    MATCH mret = MATCHnomatch;\n+    for (int i = 0; i < a_count; i++)\n+    {\n+        bool islvalue = false;\n+        Type *a = aliasThisOf(from, i, &islvalue);\n+        if (!a)\n+            continue;\n+\n+        unsigned tatt = a->aliasthislock;\n+        a->aliasthislock |= RECtracing;\n+        MATCH m = a->implicitConvTo(to);\n+        a->aliasthislock = tatt;\n+\n+        if (m != MATCHnomatch)\n+        {\n+            if (*state == 0)\n+            {\n+                // the first match\n+                *state = 1;\n+                mret = m;\n+                matchname->printf(\"%s.%s\", buff->peekString(), (*ad->aliasThisSymbols)[i]->toChars());\n+            }\n+            else if (*state == 1)\n+            {\n+                // the second match\n+                *state = 2;\n+                err_ad->error(loc, \"There are many candidates for cast %s to %s; Candidates:\",\n+                              root_from->toChars(), to->toChars());\n+                err_ad->error(loc, \" => %s\", matchname->extractString());\n+                matchname->printf(\"%s.%s\", buff->peekString(), (*ad->aliasThisSymbols)[i]->toChars());\n+                err_ad->error(loc, \" => %s\", matchname->extractString());\n+            }\n+            else\n+            {\n+                matchname->printf(\"%s.%s\", buff->peekString(), (*ad->aliasThisSymbols)[i]->toChars());\n+                err_ad->error(loc, \" => %s\", matchname->extractString());\n+            }\n+        }\n+        else if (!(a->aliasthislock & RECtracing))\n+        {\n+            OutBuffer next_buff;\n+            next_buff.printf(\"%s.%s\", buff->peekString(), (*ad->aliasThisSymbols)[i]->toChars());\n+\n+            MATCH m2 = implicitConvToWithAliasThis(loc, a, to, root_from, &next_buff, state, matchname);\n+\n+            if (mret == MATCHnomatch)\n+                mret = m2;\n+        }\n+    }\n+\n+    if (ClassDeclaration *cd = ad ? ad->isClassDeclaration() : NULL)\n+    {\n+        for (int i = 0; i < cd->baseclasses->dim; i++)\n+        {\n+            ClassDeclaration *bd = (*cd->baseclasses)[i]->base;\n+            Type *bt = (*cd->baseclasses)[i]->type;\n+            if (!bt)\n+                bt = bd->type;\n+            if (!(bt->aliasthislock & RECtracing))\n+            {\n+                OutBuffer next_buff;\n+                next_buff.printf(\"(cast(%s)%s)\", bt->toChars(), buff->peekString());\n+\n+                MATCH m2 = implicitConvToWithAliasThis(loc, bt, to, root_from, &next_buff, state, matchname);\n+\n+                if (mret == MATCHnomatch)\n+                    mret = m2;\n+            }\n+        }\n+    }\n+    from->aliasthislock = oldatlock;\n+    return mret;\n+}\n+\n+void getAliasThisTypes(Type *t, Types *ret, Bools *islvalues)","path":"src/aliasthis.c","position":315,"original_position":315,"commit_id":"5b40cb37ab0439f0cc82cab68a197bdbaaf66946","original_commit_id":"5b40cb37ab0439f0cc82cab68a197bdbaaf66946","user":{"login":"WalterBright","id":568298,"avatar_url":"https://avatars.githubusercontent.com/u/568298?v=3","gravatar_id":"","url":"https://api.github.com/users/WalterBright","html_url":"https://github.com/WalterBright","followers_url":"https://api.github.com/users/WalterBright/followers","following_url":"https://api.github.com/users/WalterBright/following{/other_user}","gists_url":"https://api.github.com/users/WalterBright/gists{/gist_id}","starred_url":"https://api.github.com/users/WalterBright/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WalterBright/subscriptions","organizations_url":"https://api.github.com/users/WalterBright/orgs","repos_url":"https://api.github.com/users/WalterBright/repos","events_url":"https://api.github.com/users/WalterBright/events{/privacy}","received_events_url":"https://api.github.com/users/WalterBright/received_events","type":"User","site_admin":false},"body":"what does this function do?","created_at":"2015-06-08T00:37:54Z","updated_at":"2015-06-08T00:37:54Z","html_url":"https://github.com/D-Programming-Language/dmd/pull/3998#discussion_r31882863","pull_request_url":"https://api.github.com/repos/D-Programming-Language/dmd/pulls/3998","_links":{"self":{"href":"https://api.github.com/repos/D-Programming-Language/dmd/pulls/comments/31882863"},"html":{"href":"https://github.com/D-Programming-Language/dmd/pull/3998#discussion_r31882863"},"pull_request":{"href":"https://api.github.com/repos/D-Programming-Language/dmd/pulls/3998"}}},"pull_request":{"url":"https://api.github.com/repos/D-Programming-Language/dmd/pulls/3998","id":21292125,"html_url":"https://github.com/D-Programming-Language/dmd/pull/3998","diff_url":"https://github.com/D-Programming-Language/dmd/pull/3998.diff","patch_url":"https://github.com/D-Programming-Language/dmd/pull/3998.patch","issue_url":"https://api.github.com/repos/D-Programming-Language/dmd/issues/3998","number":3998,"state":"open","locked":false,"title":"[tdpl] Multiple alias this","user":{"login":"IgorStepanov","id":1143799,"avatar_url":"https://avatars.githubusercontent.com/u/1143799?v=3","gravatar_id":"","url":"https://api.github.com/users/IgorStepanov","html_url":"https://github.com/IgorStepanov","followers_url":"https://api.github.com/users/IgorStepanov/followers","following_url":"https://api.github.com/users/IgorStepanov/following{/other_user}","gists_url":"https://api.github.com/users/IgorStepanov/gists{/gist_id}","starred_url":"https://api.github.com/users/IgorStepanov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/IgorStepanov/subscriptions","organizations_url":"https://api.github.com/users/IgorStepanov/orgs","repos_url":"https://api.github.com/users/IgorStepanov/repos","events_url":"https://api.github.com/users/IgorStepanov/events{/privacy}","received_events_url":"https://api.github.com/users/IgorStepanov/received_events","type":"User","site_admin":false},"body":"This PR introduces multiple alias this.\r\nThe old alias this implemenation doesn't imply alias this conflicts.\r\nAll alias this-es in old implementation are serializable: compiler successively applies a, a->aliasthis, a->aliasthis->aliasthis while right expression is not found.\r\n\r\nThis implementation allows tree of alias this subtypes.\r\nType can has a direct \"alias this\"-es and \"alias this\"-es, inherited from base classes/interfaces. Thus, there can be conflict between several matching \"alias this\"-es.\r\nIn common case compile should raise error if several \"alias this\"-es have found.\r\nHowever, in the next situation conflict can be resolved:\r\n```\r\nstruct Test9a\r\n{\r\n    int a;\r\n    alias a this;\r\n}\r\n\r\nstruct Test9b\r\n{\r\n    int a;\r\n    alias a this;\r\n}\r\n\r\nstruct Test9\r\n{\r\n    Test9a a;\r\n    Test9b b;\r\n    int c;\r\n    alias a this;\r\n    alias b this;\r\n    alias c this;\r\n}\r\n\r\nvoid test()\r\n{\r\n    Test9 t9;\r\n    int a = t9;\r\n}\r\n```\r\n\r\nWhen we try to cast `Test9` to int we can find several variants: `t9.a.a`, `t9.b.a`, `t9.c`.\r\nHowever, `t9.c` is preferred, because `Test9` author is explicitly pointed out that `Test9` should be converted to `int` through `c` field. This magic works only if we have exact match. `short a = t9;` causes error.\r\n\r\nThis PR have a one limitation: it doesn't support multiple tuple alias this. It don't clearly understand how them should works.   Multiple tuple alias this can be implemented in future in a separate PR.\r\n","created_at":"2014-09-16T11:40:59Z","updated_at":"2015-06-08T00:37:54Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4cc8f4fecce6bb29cd7b7848e1f3523ce10ba796","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/D-Programming-Language/dmd/pulls/3998/commits","review_comments_url":"https://api.github.com/repos/D-Programming-Language/dmd/pulls/3998/comments","review_comment_url":"https://api.github.com/repos/D-Programming-Language/dmd/pulls/comments{/number}","comments_url":"https://api.github.com/repos/D-Programming-Language/dmd/issues/3998/comments","statuses_url":"https://api.github.com/repos/D-Programming-Language/dmd/statuses/5b40cb37ab0439f0cc82cab68a197bdbaaf66946","head":{"label":"IgorStepanov:multiple-alias-this","ref":"multiple-alias-this","sha":"5b40cb37ab0439f0cc82cab68a197bdbaaf66946","user":{"login":"IgorStepanov","id":1143799,"avatar_url":"https://avatars.githubusercontent.com/u/1143799?v=3","gravatar_id":"","url":"https://api.github.com/users/IgorStepanov","html_url":"https://github.com/IgorStepanov","followers_url":"https://api.github.com/users/IgorStepanov/followers","following_url":"https://api.github.com/users/IgorStepanov/following{/other_user}","gists_url":"https://api.github.com/users/IgorStepanov/gists{/gist_id}","starred_url":"https://api.github.com/users/IgorStepanov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/IgorStepanov/subscriptions","organizations_url":"https://api.github.com/users/IgorStepanov/orgs","repos_url":"https://api.github.com/users/IgorStepanov/repos","events_url":"https://api.github.com/users/IgorStepanov/events{/privacy}","received_events_url":"https://api.github.com/users/IgorStepanov/received_events","type":"User","site_admin":false},"repo":{"id":8583804,"name":"dmd","full_name":"IgorStepanov/dmd","owner":{"login":"IgorStepanov","id":1143799,"avatar_url":"https://avatars.githubusercontent.com/u/1143799?v=3","gravatar_id":"","url":"https://api.github.com/users/IgorStepanov","html_url":"https://github.com/IgorStepanov","followers_url":"https://api.github.com/users/IgorStepanov/followers","following_url":"https://api.github.com/users/IgorStepanov/following{/other_user}","gists_url":"https://api.github.com/users/IgorStepanov/gists{/gist_id}","starred_url":"https://api.github.com/users/IgorStepanov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/IgorStepanov/subscriptions","organizations_url":"https://api.github.com/users/IgorStepanov/orgs","repos_url":"https://api.github.com/users/IgorStepanov/repos","events_url":"https://api.github.com/users/IgorStepanov/events{/privacy}","received_events_url":"https://api.github.com/users/IgorStepanov/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/IgorStepanov/dmd","description":"dmd D Programming Language compiler","fork":true,"url":"https://api.github.com/repos/IgorStepanov/dmd","forks_url":"https://api.github.com/repos/IgorStepanov/dmd/forks","keys_url":"https://api.github.com/repos/IgorStepanov/dmd/keys{/key_id}","collaborators_url":"https://api.github.com/repos/IgorStepanov/dmd/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/IgorStepanov/dmd/teams","hooks_url":"https://api.github.com/repos/IgorStepanov/dmd/hooks","issue_events_url":"https://api.github.com/repos/IgorStepanov/dmd/issues/events{/number}","events_url":"https://api.github.com/repos/IgorStepanov/dmd/events","assignees_url":"https://api.github.com/repos/IgorStepanov/dmd/assignees{/user}","branches_url":"https://api.github.com/repos/IgorStepanov/dmd/branches{/branch}","tags_url":"https://api.github.com/repos/IgorStepanov/dmd/tags","blobs_url":"https://api.github.com/repos/IgorStepanov/dmd/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/IgorStepanov/dmd/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/IgorStepanov/dmd/git/refs{/sha}","trees_url":"https://api.github.com/repos/IgorStepanov/dmd/git/trees{/sha}","statuses_url":"https://api.github.com/repos/IgorStepanov/dmd/statuses/{sha}","languages_url":"https://api.github.com/repos/IgorStepanov/dmd/languages","stargazers_url":"https://api.github.com/repos/IgorStepanov/dmd/stargazers","contributors_url":"https://api.github.com/repos/IgorStepanov/dmd/contributors","subscribers_url":"https://api.github.com/repos/IgorStepanov/dmd/subscribers","subscription_url":"https://api.github.com/repos/IgorStepanov/dmd/subscription","commits_url":"https://api.github.com/repos/IgorStepanov/dmd/commits{/sha}","git_commits_url":"https://api.github.com/repos/IgorStepanov/dmd/git/commits{/sha}","comments_url":"https://api.github.com/repos/IgorStepanov/dmd/comments{/number}","issue_comment_url":"https://api.github.com/repos/IgorStepanov/dmd/issues/comments{/number}","contents_url":"https://api.github.com/repos/IgorStepanov/dmd/contents/{+path}","compare_url":"https://api.github.com/repos/IgorStepanov/dmd/compare/{base}...{head}","merges_url":"https://api.github.com/repos/IgorStepanov/dmd/merges","archive_url":"https://api.github.com/repos/IgorStepanov/dmd/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/IgorStepanov/dmd/downloads","issues_url":"https://api.github.com/repos/IgorStepanov/dmd/issues{/number}","pulls_url":"https://api.github.com/repos/IgorStepanov/dmd/pulls{/number}","milestones_url":"https://api.github.com/repos/IgorStepanov/dmd/milestones{/number}","notifications_url":"https://api.github.com/repos/IgorStepanov/dmd/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/IgorStepanov/dmd/labels{/name}","releases_url":"https://api.github.com/repos/IgorStepanov/dmd/releases{/id}","created_at":"2013-03-05T16:21:41Z","updated_at":"2014-12-07T07:02:07Z","pushed_at":"2015-06-05T21:56:39Z","git_url":"git://github.com/IgorStepanov/dmd.git","ssh_url":"git@github.com:IgorStepanov/dmd.git","clone_url":"https://github.com/IgorStepanov/dmd.git","svn_url":"https://github.com/IgorStepanov/dmd","homepage":"d-programming-language.org","size":54672,"stargazers_count":0,"watchers_count":0,"language":"C","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"D-Programming-Language:master","ref":"master","sha":"e8cc0dec961ab511136bd5c41ebeae5b062e3a66","user":{"login":"D-Programming-Language","id":565913,"avatar_url":"https://avatars.githubusercontent.com/u/565913?v=3","gravatar_id":"","url":"https://api.github.com/users/D-Programming-Language","html_url":"https://github.com/D-Programming-Language","followers_url":"https://api.github.com/users/D-Programming-Language/followers","following_url":"https://api.github.com/users/D-Programming-Language/following{/other_user}","gists_url":"https://api.github.com/users/D-Programming-Language/gists{/gist_id}","starred_url":"https://api.github.com/users/D-Programming-Language/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/D-Programming-Language/subscriptions","organizations_url":"https://api.github.com/users/D-Programming-Language/orgs","repos_url":"https://api.github.com/users/D-Programming-Language/repos","events_url":"https://api.github.com/users/D-Programming-Language/events{/privacy}","received_events_url":"https://api.github.com/users/D-Programming-Language/received_events","type":"Organization","site_admin":false},"repo":{"id":1257070,"name":"dmd","full_name":"D-Programming-Language/dmd","owner":{"login":"D-Programming-Language","id":565913,"avatar_url":"https://avatars.githubusercontent.com/u/565913?v=3","gravatar_id":"","url":"https://api.github.com/users/D-Programming-Language","html_url":"https://github.com/D-Programming-Language","followers_url":"https://api.github.com/users/D-Programming-Language/followers","following_url":"https://api.github.com/users/D-Programming-Language/following{/other_user}","gists_url":"https://api.github.com/users/D-Programming-Language/gists{/gist_id}","starred_url":"https://api.github.com/users/D-Programming-Language/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/D-Programming-Language/subscriptions","organizations_url":"https://api.github.com/users/D-Programming-Language/orgs","repos_url":"https://api.github.com/users/D-Programming-Language/repos","events_url":"https://api.github.com/users/D-Programming-Language/events{/privacy}","received_events_url":"https://api.github.com/users/D-Programming-Language/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/D-Programming-Language/dmd","description":"dmd D Programming Language compiler","fork":false,"url":"https://api.github.com/repos/D-Programming-Language/dmd","forks_url":"https://api.github.com/repos/D-Programming-Language/dmd/forks","keys_url":"https://api.github.com/repos/D-Programming-Language/dmd/keys{/key_id}","collaborators_url":"https://api.github.com/repos/D-Programming-Language/dmd/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/D-Programming-Language/dmd/teams","hooks_url":"https://api.github.com/repos/D-Programming-Language/dmd/hooks","issue_events_url":"https://api.github.com/repos/D-Programming-Language/dmd/issues/events{/number}","events_url":"https://api.github.com/repos/D-Programming-Language/dmd/events","assignees_url":"https://api.github.com/repos/D-Programming-Language/dmd/assignees{/user}","branches_url":"https://api.github.com/repos/D-Programming-Language/dmd/branches{/branch}","tags_url":"https://api.github.com/repos/D-Programming-Language/dmd/tags","blobs_url":"https://api.github.com/repos/D-Programming-Language/dmd/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/D-Programming-Language/dmd/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/D-Programming-Language/dmd/git/refs{/sha}","trees_url":"https://api.github.com/repos/D-Programming-Language/dmd/git/trees{/sha}","statuses_url":"https://api.github.com/repos/D-Programming-Language/dmd/statuses/{sha}","languages_url":"https://api.github.com/repos/D-Programming-Language/dmd/languages","stargazers_url":"https://api.github.com/repos/D-Programming-Language/dmd/stargazers","contributors_url":"https://api.github.com/repos/D-Programming-Language/dmd/contributors","subscribers_url":"https://api.github.com/repos/D-Programming-Language/dmd/subscribers","subscription_url":"https://api.github.com/repos/D-Programming-Language/dmd/subscription","commits_url":"https://api.github.com/repos/D-Programming-Language/dmd/commits{/sha}","git_commits_url":"https://api.github.com/repos/D-Programming-Language/dmd/git/commits{/sha}","comments_url":"https://api.github.com/repos/D-Programming-Language/dmd/comments{/number}","issue_comment_url":"https://api.github.com/repos/D-Programming-Language/dmd/issues/comments{/number}","contents_url":"https://api.github.com/repos/D-Programming-Language/dmd/contents/{+path}","compare_url":"https://api.github.com/repos/D-Programming-Language/dmd/compare/{base}...{head}","merges_url":"https://api.github.com/repos/D-Programming-Language/dmd/merges","archive_url":"https://api.github.com/repos/D-Programming-Language/dmd/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/D-Programming-Language/dmd/downloads","issues_url":"https://api.github.com/repos/D-Programming-Language/dmd/issues{/number}","pulls_url":"https://api.github.com/repos/D-Programming-Language/dmd/pulls{/number}","milestones_url":"https://api.github.com/repos/D-Programming-Language/dmd/milestones{/number}","notifications_url":"https://api.github.com/repos/D-Programming-Language/dmd/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/D-Programming-Language/dmd/labels{/name}","releases_url":"https://api.github.com/repos/D-Programming-Language/dmd/releases{/id}","created_at":"2011-01-15T06:53:53Z","updated_at":"2015-06-07T20:44:59Z","pushed_at":"2015-06-07T13:42:47Z","git_url":"git://github.com/D-Programming-Language/dmd.git","ssh_url":"git@github.com:D-Programming-Language/dmd.git","clone_url":"https://github.com/D-Programming-Language/dmd.git","svn_url":"https://github.com/D-Programming-Language/dmd","homepage":"dlang.org","size":98152,"stargazers_count":1022,"watchers_count":1022,"language":"C","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":335,"mirror_url":null,"open_issues_count":96,"forks":335,"open_issues":96,"watchers":1022,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/D-Programming-Language/dmd/pulls/3998"},"html":{"href":"https://github.com/D-Programming-Language/dmd/pull/3998"},"issue":{"href":"https://api.github.com/repos/D-Programming-Language/dmd/issues/3998"},"comments":{"href":"https://api.github.com/repos/D-Programming-Language/dmd/issues/3998/comments"},"review_comments":{"href":"https://api.github.com/repos/D-Programming-Language/dmd/pulls/3998/comments"},"review_comment":{"href":"https://api.github.com/repos/D-Programming-Language/dmd/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/D-Programming-Language/dmd/pulls/3998/commits"},"statuses":{"href":"https://api.github.com/repos/D-Programming-Language/dmd/statuses/5b40cb37ab0439f0cc82cab68a197bdbaaf66946"}}}}