Skip to content

Commit ceedc50

Browse files
committed
For integers we can not force to LongLong
1 parent 5bfe055 commit ceedc50

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

python/lsst/pex/config/convert.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,13 @@ def _helper(config, ps, prefix, dict_, ext_dtype=None):
8686
elif dtype is bool:
8787
ps.setBool(name, v)
8888
elif dtype is int:
89-
ps.setLongLong(name, v)
89+
# User code requires that small numbers are stored in
90+
# small integers and LongLong be reserved for larger
91+
# ints. This means that we have to either use an
92+
# optimized version of the logic from PropertySet
93+
# (we know it does not exist and that it is an integer type)
94+
# or just use the generic setter.
95+
ps.set(name, v)
9096
elif dtype is float:
9197
ps.setDouble(name, v)
9298
else:

0 commit comments

Comments
 (0)