WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
134059
REGRESSION (
r168685
): css calc() expression fails
https://bugs.webkit.org/show_bug.cgi?id=134059
Summary
REGRESSION (r168685): css calc() expression fails
hooleyhoop
Reported
2014-06-19 04:43:04 PDT
This expression no longer works.. width: calc((100% - 20px) / 3; equivalent expression still works width: calc(100%/3 - 20px/3)
Attachments
Proposed patch
(4.26 KB, patch)
2014-06-27 09:25 PDT
,
Martin Hodovan
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Simon Fraser (smfr)
Comment 1
2014-06-20 08:28:06 PDT
Regressed in
http://trac.webkit.org/changeset/168685
.
Radar WebKit Bug Importer
Comment 2
2014-06-24 00:39:16 PDT
<
rdar://problem/17431912
>
Simon Fraser (smfr)
Comment 3
2014-06-24 08:58:32 PDT
Martin, can you take a look please, so we don't have to roll out your patch?
hodovanmartin@gmail.com
Comment 4
2014-06-24 09:05:39 PDT
Yes, I am already working on it, I just need a little more time. I will upload a patch till tomorrow.
hodovanmartin@gmail.com
Comment 5
2014-06-24 12:16:56 PDT
I have reverted my repository to the revision before right my patch (
r168684
) and it does not work either. This expression can not be parsed properly because of the superfluous '(' character, but seems like it is an older issue. () However, I am glad to investigate it. The following example shows two rectangle of the same size: <div width="300px"> <div style="height:100px; width: calc((100% - 20px) / 3); border: 1px solid;" ></div> <div style="height:100px; width: calc(100%/3 - 20px/3); border: 1px solid;"></div> </div>
Simon Fraser (smfr)
Comment 6
2014-06-24 12:32:20 PDT
The test case def. worked in
http://trac.webkit.org/changeset/168684
Martin Hodovan
Comment 7
2014-06-25 02:57:11 PDT
(In reply to
comment #0
)
> This expression no longer works.. > > width: calc((100% - 20px) / 3;
I think there has been some misunderstanding here. Your first example is a malformed expression, because a closing brace is missing from the end, and therefore it can not be parsed properly. I thought that my patch has ruined some error recovery feature, which seemed a little unlikely, since my patch did not change the CSS grammar. So I double-checked it and the expression you mentioned has never worked before. (Maybe I should report it, if it needs auto-correction at all.) But now I get it. "width: calc((100% - 20px) / 3)" is now a well-formed expression and it really does not work since my patch has landed. Thank you for your patience, I will upload a fix very soon.
Martin Hodovan
Comment 8
2014-06-27 09:25:00 PDT
Created
attachment 233987
[details]
Proposed patch
WebKit Commit Bot
Comment 9
2014-06-27 11:56:10 PDT
Comment on
attachment 233987
[details]
Proposed patch Clearing flags on attachment: 233987 Committed
r170544
: <
http://trac.webkit.org/changeset/170544
>
WebKit Commit Bot
Comment 10
2014-06-27 11:56:17 PDT
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug