Merge ~dirk.zimoch/epics-base:dynamicVxWorksVmeFunctionBinding into ~epics-core/epics-base/+git/epics-base:7.0
Proposed by
Dirk Zimoch
Status: | Merged |
---|---|
Approved by: | Andrew Johnson |
Approved revision: | 251304e280c023ed72031d25981d6db4bd0b73d4 |
Merged at revision: | 220a27bdec2492f9938ccf2a275ba7d04f06cf30 |
Proposed branch: | ~dirk.zimoch/epics-base:dynamicVxWorksVmeFunctionBinding |
Merge into: | ~epics-core/epics-base/+git/epics-base:7.0 |
Diff against target: |
110 lines (+31/-17) 1 file modified
modules/libcom/src/osi/os/vxWorks/devLibVMEOSD.c (+31/-17) |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Andrew Johnson | Approve | ||
Review via email: mp+367253@code.launchpad.net |
Description of the change
Use dynamic binding for vxWorks BSP functions because some BSPs don't provide them.
To post a comment you must log in.
Why not just replace the #if lines with if (...) { and leave the bodies of the functions untouched? That would make it easier for reviewers to confirm that you aren't changing the logic at all. As it is we have to understand both the original logic and what you've replaced it with and convince ourselves that their behavior will be the same, but using run-time detection instead of compile-time. Modern compilers should generate the same code for both versions so human readability is more important than conciseness.
I know that some people don't like having multiple return statements in a function; personally I disagree with that position, especially in simple cases like these where there are no resources that need releasing.