Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(114)

Issue 130086: Adds to the minifier an optimization which takes into account user-agent info. (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
16 years, 8 months ago by MikeSamuel
Modified:
16 years, 7 months ago
Reviewers:
metaweta
CC:
google-caja-discuss_googlegroups.com
Base URL:
http://google-caja.googlecode.com/svn/trunk/
Visibility:
Public.

Description

A code minifier that can eliminate code that is not reached on a particular user agent. Most of this code is in ancillary. Please review the non ancillary bits. See http://code.google.com/p/google-caja/wiki/UserAgentContext Submitted @3827

Patch Set 1 #

Patch Set 2 : Adds to the minifier an optimization which takes into account user-agent info. #

Patch Set 3 : Adds to the minifier an optimization which takes into account user-agent info. #

Patch Set 4 : Adds to the minifier an optimization which takes into account user-agent info. #

Patch Set 5 : Adds to the minifier an optimization which takes into account user-agent info. #

Patch Set 6 : Adds to the minifier an optimization which takes into account user-agent info. #

Total comments: 4
Unified diffs Side-by-side diffs Delta from patch set Stats (+3344 lines, -62 lines) Patch
M build.xml View 1 2 3 4 5 5 chunks +52 lines, -46 lines 0 comments Download
A src/com/google/caja/ancillary/opt/ConstLocalOptimization.java View 1 chunk +215 lines, -0 lines 0 comments Download
A src/com/google/caja/ancillary/opt/EnvironmentData.java View 1 chunk +83 lines, -0 lines 0 comments Download
A src/com/google/caja/ancillary/opt/EnvironmentDatum.java View 1 chunk +49 lines, -0 lines 0 comments Download
A src/com/google/caja/ancillary/opt/Fact.java View 1 chunk +82 lines, -0 lines 0 comments Download
A src/com/google/caja/ancillary/opt/Firefox-3.0.12.env.json View 1 chunk +1 line, -0 lines 0 comments Download
A src/com/google/caja/ancillary/opt/Firefox-3.0.5.env.json View 1 chunk +1 line, -0 lines 0 comments Download
A src/com/google/caja/ancillary/opt/Firefox-3.5.3.env.json View 5 1 chunk +1 line, -0 lines 0 comments Download
A src/com/google/caja/ancillary/opt/LocalVarRenamer.java View 1 chunk +299 lines, -0 lines 0 comments Download
A src/com/google/caja/ancillary/opt/MSIE-6.0.env.json View 1 chunk +1 line, -0 lines 0 comments Download
A src/com/google/caja/ancillary/opt/ParseTreeKB.java View 1 chunk +591 lines, -0 lines 2 comments Download
A src/com/google/caja/ancillary/opt/Safari-531.9.env.json View 5 1 chunk +1 line, -0 lines 0 comments Download
A src/com/google/caja/ancillary/opt/ScopeInfo.java View 1 chunk +97 lines, -0 lines 0 comments Download
A src/com/google/caja/ancillary/opt/Use.java View 1 chunk +39 lines, -0 lines 0 comments Download
A src/com/google/caja/ancillary/opt/environment-checks.html View 1 chunk +78 lines, -0 lines 0 comments Download
A src/com/google/caja/ancillary/opt/environment-checks.js View 1 chunk +119 lines, -0 lines 0 comments Download
A src/com/google/caja/ancillary/opt/package.html View 1 chunk +143 lines, -0 lines 0 comments Download
A src/com/google/caja/ancillary/opt/table.py View 1 chunk +56 lines, -0 lines 0 comments Download
M src/com/google/caja/parser/quasiliteral/Scope.java View 1 2 3 4 5 4 chunks +26 lines, -2 lines 2 comments Download
M src/com/google/caja/plugin/BuildServiceImplementation.java View 1 2 3 4 5 4 chunks +95 lines, -11 lines 0 comments Download
M src/com/google/caja/tools/TransformAntTask.java View 2 3 4 5 2 chunks +3 lines, -1 line 0 comments Download
A tests/com/google/caja/ancillary/opt/ConstLocalOptimizationTest.java View 1 chunk +189 lines, -0 lines 0 comments Download
A tests/com/google/caja/ancillary/opt/EnvironmentChecksTest.java View 1 chunk +48 lines, -0 lines 0 comments Download
A tests/com/google/caja/ancillary/opt/LocalVarRenamerTest.java View 1 chunk +414 lines, -0 lines 0 comments Download
A tests/com/google/caja/ancillary/opt/ParseTreeKBTest.java View 1 chunk +659 lines, -0 lines 0 comments Download
M third_party/js/json_sans_eval/json_sans_eval.js View 1 2 3 4 5 2 chunks +2 lines, -2 lines 0 comments Download

Messages

Total messages: 2
metaweta
LGTM http://codereview.appspot.com/130086/diff/7001/7012 File src/com/google/caja/ancillary/opt/ParseTreeKB.java (right): http://codereview.appspot.com/130086/diff/7001/7012#newcode52 Line 52: public class ParseTreeKB { Does KB stand ...
16 years, 8 months ago (2009-10-26 23:20:11 UTC) #1
MikeSamuel
16 years, 8 months ago (2009-10-27 00:49:19 UTC) #2
http://codereview.appspot.com/130086/diff/7001/7012
File src/com/google/caja/ancillary/opt/ParseTreeKB.java (right):

http://codereview.appspot.com/130086/diff/7001/7012#newcode52
Line 52: public class ParseTreeKB {
On 2009/10/26 23:20:11, metaweta wrote:
> Does KB stand for "knowledge base"?

yes.  And kibbles & bits.

http://codereview.appspot.com/130086/diff/7001/7006
File src/com/google/caja/parser/quasiliteral/Scope.java (right):

http://codereview.appspot.com/130086/diff/7001/7006#newcode467
Line 467: * @return whether 'name' is defined as a declared function within this
On 2009/10/26 23:20:11, metaweta wrote:
> You seem to be talking about four different cases:

> 1) local var: var name = value;
> 2) formal parameter: function (name) { ... }
> 3) declared function: function name() { ... }
> 4) undefined
> 
> What does this method distinguish between?  (any of 1-3) vs 4?

LocalType does not distinguish between 1 and 2.
(3) would be LocalType.FUNCTION_DECLARED.
(4) would be a null LocalType.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b