Usage of this array seems to have been dropped by #280, but the array
remained.
Cleaning up so it doesn't allocate the array needlessly anymore.
Fixes#730.
This fixes#700 (Java is unhelpful and the Collections.unmodifiableList etc
methods don't check whether the thing is already wrapped).
These were just an assertion basically intended to find any accidental
modification of these collections, so not essential.
* Allow application.conf to override variables in reference.conf
Fixes#167
This only affects the output of `ConfigFactory.load`. It does not change
`ConfigFactory.defaultReference`. This uses the unresolved
`reference.conf` in the building of configuration in
`ConfigFactory.load`, effectively allowing `application.conf` properties
to override variable substitutions in `reference.conf`.
However, it still requires `reference.conf` to be fully resolvable, if
it isn't, an exception will be thrown. So two resolves are still done
during load, it's just that the output of the resolve of
`reference.conf` isn't used in building the final configuration. The
documentation has been updated to reflect this behavior.
The reasoning behind this change can be read about in #167, but
essentially, it is not uncommon for configuration properties to depend
on each other by default, a good example of this is directory
hierarchies, where you might have a configuration option for a base
directory, and then a configuration for the log directory that by
default is under the base directory, and within that a configuration for
individual log files which by default are under the log directory.
Without allowing variable substitutions in `reference.conf` from
`application.conf`, there is no point in defining a configuration option
for the base directory since changing it won't have any impact, and each
path defined that depends on it will have to be manually overridden.
This limitation is contrary to convention over configuration best
practices, and hence not desirable in a configuration library.
* Renamed public method to defaultReferenceUnresolved
Also added the methods to ConfigFactory, as requested in code review.