Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix #52989: DateTime parser would return an error when parsing a year…
… string (#53954) Issue #52989. Originally checked on version 1.10.0 but still relevant in the current version in master Bug: When executing the method DateTime to create a DateTime value with a string input only containing a year (ex: "2000") the method returns an 'ArgumentError: Invalid DateTime string' when it should, from what I understood, return a DateTime like 2000-01-01T00:00:00 seeing as if you call the same method with a number indicating a year (ex: 2000) the method returns correctly. Fix: The fix was simple, on the first tryparsenext_base10 block (line 207-211) where a year is parsed from the string the exit condition i > end_pos should jump into 'done' so it returns a correct value instead of 'error'
- Loading branch information