Greetings, I just landed the patches in bug 1564724. As a result, static prefs are no longer defined in modules/libpref/init/StaticPrefList.h. They are now defined in modules/libpref/init/StaticPrefList.yaml, from which a StaticPrefList.h file is generated. The format is explained in a comment at the top of StaticPrefList.yaml.
I did my best to ensure this change did not introduce any changes in behaviour. However, any change that affects 900+ prefs has non-zero risk, so please be on the lookout for any regressions. The riskiest part of the change is that the old header file was preprocessed with the C++ preprocessor, while the new one uses our own preprocessor.py, and it's possible there could be differences caused by that because the set of constants defined is slightly different. The change to YAML has some minor immediate benefits. - Static pref definitions are more concise (no redundancy) and easier to read. - Naming inconsistencies for getters are no longer possible. The change will also allow some larger benefits in the immediate future. - Rust access to static prefs can become easier (bug 1563555 <https://bugzilla.mozilla.org/show_bug.cgi?id=1563555>). - StaticPrefList.h (which is generated from StaticPrefList.yaml) will be able to be split into pieces, resulting in much less recompilation each time a single static pref is changed (bug 1563139 <https://bugzilla.mozilla.org/show_bug.cgi?id=1563139>). - It will be possible to add checks for duplication with prefs defined in modules/libpref/init/all.js (bug 1566315 <https://bugzilla.mozilla.org/show_bug.cgi?id=1566315>). Please let me know if you have any questions. Nick _______________________________________________ dev-platform mailing list dev-platform@lists.mozilla.org https://lists.mozilla.org/listinfo/dev-platform