URL: https://github.com/freeipa/freeipa/pull/410
Title: #410: ipa-kdb: support KDB DAL version 6.1

simo5 commented:
"""
Also I know you can use ifdefs to avoid copy&pasting large parts of the 
structure initialization but I would prefer 3 separate full inits based only on 
ifdefs on the DAL version numbers.
in pseudo:
if v5:
  vtable = { ... }
elif v6.0:
  vtable = { ... }
elid v6.1:
  vtable = { ... }
else:
  error!

Those tables cannot change so using ifdefs in them can only risk to introduce 
bugs in one of the versions rather than help reduce code duplication.
"""

See the full comment at 
https://github.com/freeipa/freeipa/pull/410#issuecomment-274808126
-- 
Manage your subscription for the Freeipa-devel mailing list:
https://www.redhat.com/mailman/listinfo/freeipa-devel
Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code

Reply via email to