{"action":"opened","issue":{"url":"https://api.github.com/repos/sbt/sbt-datatype/issues/49","repository_url":"https://api.github.com/repos/sbt/sbt-datatype","labels_url":"https://api.github.com/repos/sbt/sbt-datatype/issues/49/labels{/name}","comments_url":"https://api.github.com/repos/sbt/sbt-datatype/issues/49/comments","events_url":"https://api.github.com/repos/sbt/sbt-datatype/issues/49/events","html_url":"https://github.com/sbt/sbt-datatype/issues/49","id":188906869,"number":49,"title":"Default Arguments vs Interspersed Growth (Design Decision)","user":{"login":"dwijnand","id":344610,"avatar_url":"https://avatars.githubusercontent.com/u/344610?v=3","gravatar_id":"","url":"https://api.github.com/users/dwijnand","html_url":"https://github.com/dwijnand","followers_url":"https://api.github.com/users/dwijnand/followers","following_url":"https://api.github.com/users/dwijnand/following{/other_user}","gists_url":"https://api.github.com/users/dwijnand/gists{/gist_id}","starred_url":"https://api.github.com/users/dwijnand/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dwijnand/subscriptions","organizations_url":"https://api.github.com/users/dwijnand/orgs","repos_url":"https://api.github.com/users/dwijnand/repos","events_url":"https://api.github.com/users/dwijnand/events{/privacy}","received_events_url":"https://api.github.com/users/dwijnand/received_events","type":"User","site_admin":false},"labels":[{"id":220827347,"url":"https://api.github.com/repos/sbt/sbt-datatype/labels/question","name":"question","color":"cc317c","default":true}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-11-12T11:27:05Z","updated_at":"2016-11-12T11:27:05Z","closed_at":null,"body":"While reviewing #44 @eed3si9n noted that the use of default arguments (in the companion object's `apply`, the constructor, and the `copy` method) moves the default value to the call-site, where it can't be changed in a later version of sbt when we (eg) flip the default from `false` to `true`.\r\n\r\nTurns out (I didn't know this) that default arguments are encoded at the definition site as (for instance) `copy$default$1`.\r\n\r\nThis makes the order of parameters significant, whereby adding a property other than the end can easily cause binary incompatibilities. Thus @eed3si9n opened #48.\r\n\r\nThe design decision to make is whether to:\r\n\r\n1. Allow the use of default arguments, but require properties to be added to the end\r\n2. Allow properties to be added anywhere l, but forgo the use of default arguments and therefore the copy method and requiring abundant use of the withXYZ methods for non-required parameters, even on first construction.\r\n\r\nTo help evaluating this decision I'm going to rework my patch sbt/librarymanagement#55, with a build of sbt-datatype that doesn't use default arguments, so we can see the diff."}}
{"actor":{"display_login":"dwijnand"}}