2

English is not my primary language so I have hard time with this problem. I am currently writing comments to computer code. There is setting that enable/disable some functionality. What would be correct comment to this? Is there noun form of word enable? The comment would be something like:

Sets ??? of functionality.

I am thinking about:

Sets working state of functionality.

Sets turning on/off of functionality.

Sets availability of functionality.

But it just seems wrong. Is there some better words that could describe this?

2
  • Tangentially: Be wary of terse comments in code -- you'll need the meaning later. For example, "If true, then _____. If false, then _____." Oftentimes in code, true/false settings are not exactly opposite in the outcome. Commented Nov 20, 2014 at 13:59
  • Sets / resets functionality.
    – Kris
    Commented Nov 20, 2014 at 15:33

2 Answers 2

2

You could write

enables or disables the functionality

or

activates or deactivates the functionality

or, less comprehensibly

toggles the operation of the functionality

1
  • 1
    Thank you. 'enables or disables the functionality' suits me, cannot believe I didn't think of that. Well I should think harder next time :)
    – benderto
    Commented Nov 20, 2014 at 13:17
0

A part of me thinks, in certain contexts, the word "parity" would work here.

"Toggles the parity of the machine state."

1
  • 1
    Which definition of parity are you using? Commented Jul 18, 2022 at 14:12

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .