On May 22, 2018, at 06:22, Clemens Lang wrote: > On 22 May, 2018, at 13:12, Ryan Schmidt wrote: > >> I'm confused by the inconsistency between variables like macosx_version and >> xcodeversion, and the macports_version proc. > > xcodeversion and macosx_version are handled very different in the code. > xcodeversion, xcodebuildcmd and developer_dir are deferred options, i.e. they > are only copied into the port interpreter when they are read. macosx_version > is copied immediately. You can compare them from a user's PoV, but they are > very different from the system view.
I do compare it from the user's point of view, and I find the difference in how they are handled to be completely illogical. While I'm arguing about it, it should have been xcode_version, not xcodeversion. > One big downside of using variables (apart from the non-obvious property of > being constant) is documentation. There is no good place in the code to > document these variables – consequently we do not have any documentation for > macosx_version, but macports::version is documented [1]. I believe all public > API available in macports1.0 should be documented. I guess we should document variables then.