Correct behavior for registry incr
Summary:
The proc didn't support registry incr <variable> <term>,
only registry incr <variable>.
Fixes T793.
Test Plan:
Actual incrementation
- Increment a non existing variable
- Increment the same variable with the default term 1
- Increment the same variable with an arbitrary term
- Ensure the final value is correct
Error handling
- Increment with a non integer term
Tested on Wearg
16:22:08 <Dereckson> .s Core 16:22:09 <Dereckson> .tcl registry incr quux 16:22:09 <Wearg> Tcl: 16:22:12 <Dereckson> .tcl registry incr quux 16:22:12 <Wearg> Tcl: 16:22:13 <Dereckson> .tcl registry incr quux 16:22:13 <Wearg> Tcl: 16:22:14 <Dereckson> .tcl registry incr quux 16:22:14 <Wearg> Tcl: 16:22:16 <Dereckson> .tcl registry incr quux 9 16:22:16 <Wearg> Tcl: 16:22:18 <Dereckson> .tcl registry incr quux foo 16:22:18 <Wearg> Tcl error: The increment term must be integer. 16:22:29 <Dereckson> .tcl registry get quux 16:22:29 <Wearg> Tcl: 13
Reviewers: dereckson
Maniphest Tasks: T793
Differential Revision: http://devcentral.nasqueron.org/D349