Files
codeql/python/ql/test/query-tests/Variables/undefined/odasa6418.py
2018-11-19 15:15:54 +00:00

20 lines
418 B
Python

import sys
def bump_version(version):
try:
parts = map(int, version.split('.'))
except ValueError:
fail('Current version is not numeric')
parts[-1] += 1
return '.'.join(map(str, parts))
def fail(message):
print(message)
sys.exit(1)
# To get the FP result reported in ODASA-6418,
#bump_version must be called (directly or transitively) from the module scope
bump_version()