mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-07-11 22:03:01 -06:00
Core: CParser::ReadDouble now allows '.707' (but IsDouble still false)
git-svn-id: svn://ultimatepp.org/upp/trunk@7967 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
b4952fc9b6
commit
a42853cdfd
2 changed files with 6 additions and 3 deletions
|
|
@ -280,7 +280,7 @@ double CParser::ReadDouble() throw(Error)
|
|||
{
|
||||
LTIMING("ReadDouble");
|
||||
int sign = Sgn();
|
||||
if(!IsDigit(*term))
|
||||
if(!IsDigit(*term) && *term != '.')
|
||||
ThrowError("missing number");
|
||||
double n = 0;
|
||||
while(IsDigit(*term))
|
||||
|
|
|
|||
|
|
@ -99,8 +99,11 @@ Painter& Painter::Path(CParser& p)
|
|||
|
||||
Painter& Painter::Path(const char *path)
|
||||
{
|
||||
CParser p(path);
|
||||
Path(p);
|
||||
try {
|
||||
CParser p(path);
|
||||
Path(p);
|
||||
}
|
||||
catch(CParser::Error) {}
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue