google-caja-discuss

[Prev] Thread [Next]  |  [Prev] Date [Next]

[Caja] Re: Fixes uses of cajita's taming API and improves primFreeze speed. erights Fri Jun 26 00:00:28 2009


Still looking at your first issue below -- the disabling of some taming
methods by cajita-debugmode -- in light of new issue 1058. This first
issue is not yet addressed. All the rest are ready for judgment. Thanks.


http://codereview.appspot.com/50041/diff/4001/4009
File src/com/google/caja/cajita-debugmode.js (right):

http://codereview.appspot.com/50041/diff/4001/4009#newcode355
Line 355: 'grantEnum', noop,
Looking at this disabling again in light of issue 1058.

http://codereview.appspot.com/50041/diff/4001/4015
File src/com/google/caja/demos/calendar/demo-cajoled.html (right):

http://codereview.appspot.com/50041/diff/4001/4015#newcode152
Line 152: ___.ctor(StringInterpolation, Object, 'StringInterpolation');
On 2009/05/20 20:09:27, BenL wrote:
NiceNeighbour doesn't explain what optSuper and optName are for.

Done.

http://codereview.appspot.com/50041/diff/4001/4013
File src/com/google/caja/demos/lolcat-search/search.html (right):

http://codereview.appspot.com/50041/diff/4001/4013#newcode66
Line 66: ___.grantRead(___.sharedImports, 'StringInterpolation');
On 2009/05/20 20:09:27, BenL wrote:
Why not ___.grantFunc and eliminate ___.frozenFunc above?

Done.

http://codereview.appspot.com/50041/diff/4001/4002
File
tests/com/google/caja/parser/quasiliteral/DefaultValijaRewriterTest.java
(right):

http://codereview.appspot.com/50041/diff/4001/4002#newcode492
Line 492: "___.grantFunc(testImports, 'assertEquals');" +
On 2009/05/20 20:09:27, BenL wrote:
Are both the frozenFunc and grantFunc calls needed? NiceNeighbour
suggests not.

Done.

http://codereview.appspot.com/50041/diff/4001/4003
File tests/com/google/caja/parser/quasiliteral/taming_test.html (right):

http://codereview.appspot.com/50041/diff/4001/4003#newcode88
Line 88: ___.handleGeneric(MyRootNamespace.SubSpace, 'attenuated',
function (f) {
On 2009/05/20 20:09:27, BenL wrote:
I'm not sure I like the name ... shouldn't this (and friends) be
handleGenericFunc?

The naming style used by these taming functions is to use *Func only for
marking things as simple-functions, which are first class in Cajita. All
the others functions for taming methods assume that the function
involved is exophoric, and so shouldn't be accessible from Cajita.
Perhaps handleGenericMethod would be clearer? I think I'll leave this
alone.

http://codereview.appspot.com/50041