mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Accept prices of the form n.nnne[+-]nn, i.e. with an exponent.
An example requiring this is currency conversion from IDR to USD.
This commit is contained in:
@@ -187,7 +187,7 @@ sub schemify_num {
|
||||
|
||||
if(!$numstr) { return "failed-conversion"; }
|
||||
|
||||
if($numstr =~ /^\s*(\d+(\.\d+)?)$/o) {
|
||||
if($numstr =~ /^\s*(\d+(\.\d+)?([eE][+-]?\d+)?)$/o) {
|
||||
return $1;
|
||||
} else {
|
||||
return "failed-conversion";
|
||||
|
||||
Reference in New Issue
Block a user