This cast is not OK. Since config values can be negative, we must ensure that they don't underflow when casted. If they are negative, we probably want to normalize them to their default value (i.e. 2 context lines).