{"action":"created","issue":{"url":"https://api.github.com/repos/dhall-lang/dhall-haskell/issues/406","repository_url":"https://api.github.com/repos/dhall-lang/dhall-haskell","labels_url":"https://api.github.com/repos/dhall-lang/dhall-haskell/issues/406/labels{/name}","comments_url":"https://api.github.com/repos/dhall-lang/dhall-haskell/issues/406/comments","events_url":"https://api.github.com/repos/dhall-lang/dhall-haskell/issues/406/events","html_url":"https://github.com/dhall-lang/dhall-haskell/issues/406","id":326824485,"number":406,"title":"Odd representation of leading .. in import paths","user":{"login":"quasicomputational","id":33460485,"avatar_url":"https://avatars3.githubusercontent.com/u/33460485?v=4","gravatar_id":"","url":"https://api.github.com/users/quasicomputational","html_url":"https://github.com/quasicomputational","followers_url":"https://api.github.com/users/quasicomputational/followers","following_url":"https://api.github.com/users/quasicomputational/following{/other_user}","gists_url":"https://api.github.com/users/quasicomputational/gists{/gist_id}","starred_url":"https://api.github.com/users/quasicomputational/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/quasicomputational/subscriptions","organizations_url":"https://api.github.com/users/quasicomputational/orgs","repos_url":"https://api.github.com/users/quasicomputational/repos","events_url":"https://api.github.com/users/quasicomputational/events{/privacy}","received_events_url":"https://api.github.com/users/quasicomputational/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-05-27T15:16:40Z","updated_at":"2018-05-27T17:04:45Z","closed_at":null,"author_association":"NONE","body":"To represent an import path like `../foo/bar` using the API, you need to write `Local Parent (File (Directory [\"foo\"]) \"bar\")`. But importing `../../foo/bar` needs `Local Parent (File (Directory [\"foo\", \"..\"]) \"bar\")`; the first `..` gets special treatment not accorded to the second. And importing `./../../foo/bar`, which is equivalent, could be represented as `Local Here (File (Directory [\"foo\", \"..\", \"..\"]) \"bar\")`.\r\n\r\nI think it would be simpler and more uniform to just drop the `Parent` constructor from `FilePrefix`, and put `..` segments in the `Directory`. Alternatively, if it's desired to keep `..` out of the `Directory`, then the `Here` constructor could take a `Natural` saying how many directories to go upwards, and then the documentation will need to state that `..` segments shouldn't be present in a `Directory`."},"comment":{"url":"https://api.github.com/repos/dhall-lang/dhall-haskell/issues/comments/392347756","html_url":"https://github.com/dhall-lang/dhall-haskell/issues/406#issuecomment-392347756","issue_url":"https://api.github.com/repos/dhall-lang/dhall-haskell/issues/406","id":392347756,"user":{"login":"Gabriel439","id":1313787,"avatar_url":"https://avatars3.githubusercontent.com/u/1313787?v=4","gravatar_id":"","url":"https://api.github.com/users/Gabriel439","html_url":"https://github.com/Gabriel439","followers_url":"https://api.github.com/users/Gabriel439/followers","following_url":"https://api.github.com/users/Gabriel439/following{/other_user}","gists_url":"https://api.github.com/users/Gabriel439/gists{/gist_id}","starred_url":"https://api.github.com/users/Gabriel439/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Gabriel439/subscriptions","organizations_url":"https://api.github.com/users/Gabriel439/orgs","repos_url":"https://api.github.com/users/Gabriel439/repos","events_url":"https://api.github.com/users/Gabriel439/events{/privacy}","received_events_url":"https://api.github.com/users/Gabriel439/received_events","type":"User","site_admin":false},"created_at":"2018-05-27T17:04:45Z","updated_at":"2018-05-27T17:04:45Z","author_association":"COLLABORATOR","body":"@quasicomputational: Yeah, that seems reasonable.  The only reason the Haskell implementation does it this way is to match the standard as closely as possible, but what you're proposing is semantically equivalent"}}
{"actor":{"display_login":"Gabriel439"}}