Skip to content

Wrong line number in some cases. #2

@CoolTomatos

Description

@CoolTomatos

For example:

In MATH-101b:

377 | if (
378 |     source.substring(startIndex, endIndex).compareTo(
379 |     getImaginaryCharacter()) != 0) {
380 |     // set index back to initial, error index should be the start index
381 |     // character examined.
382 |     pos.setIndex(initialIndex);
383 |     pos.setErrorIndex(startIndex);
384 |     return null;
385 | }

The exception is thrown from substring(int, int) at line 378, but in JCrashPack it was logged as 377.

In LANG-44b:

193 | if (dec == null
194 |     && exp == null
195 |     && (numeric.charAt(0) == '-' && isDigits(numeric.substring(1)) || isDigits(numeric))) {
196 |     try {
197 |         return createLong(numeric);
198 |     } catch (NumberFormatException nfe) {
199 |         //Too big for a long
200 |     }
201 |     return createBigInteger(numeric);
202 |
203 | }

The exception is actually thrown from charAt(int) at line 195, but in JCrashPack it was logged as 193

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions