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

Issue 7487046: Use RuntimeInliner to provide the generator common code. (re-remove TODOs) (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 7 months ago by usrbincc
Modified:
11 years, 7 months ago
Reviewers:
arv
CC:
traceur-compiler-reviews_googlegroups.com
Base URL:
https://code.google.com/p/traceur-compiler/@master
Visibility:
Public.

Description

Use RuntimeInliner to provide the generator common code. BUG=None TEST=None

Patch Set 1 #

Patch Set 2 : Remove out-of-date TODOs. #

Total comments: 1

Patch Set 3 : merged preceding, updated JSDoc. #

Total comments: 1

Patch Set 4 : Remove out-of-date TODOs (slight return). #

Total comments: 2

Patch Set 5 : Remove $varName, fix/add JSDoc. #

Total comments: 3
Unified diffs Side-by-side diffs Delta from patch set Stats (+63 lines, -47 lines) Patch
M src/codegeneration/GeneratorTransformPass.js View 1 2 3 4 3 chunks +15 lines, -5 lines 0 comments Download
M src/codegeneration/ProgramTransformer.js View 1 chunk +1 line, -0 lines 0 comments Download
M src/codegeneration/generator/GeneratorTransformer.js View 1 2 3 4 8 chunks +47 lines, -42 lines 3 comments Download

Messages

Total messages: 8
arv
LGTM https://codereview.appspot.com/7487046/diff/2001/src/codegeneration/generator/GeneratorTransformer.js File src/codegeneration/generator/GeneratorTransformer.js (right): https://codereview.appspot.com/7487046/diff/2001/src/codegeneration/generator/GeneratorTransformer.js#newcode88 src/codegeneration/generator/GeneratorTransformer.js:88: * @param {ErrorReporter} reporter Add @param for runtimeInliner ...
11 years, 7 months ago (2013-03-13 22:28:44 UTC) #1
usrbincc
Updated JSDoc for GeneratorTransformer constructor. I learned from this "patch series" experiment that if possible, ...
11 years, 7 months ago (2013-03-14 21:22:14 UTC) #2
usrbincc
https://codereview.appspot.com/7487046/diff/6001/src/codegeneration/generator/GeneratorTransformer.js File src/codegeneration/generator/GeneratorTransformer.js (right): https://codereview.appspot.com/7487046/diff/6001/src/codegeneration/generator/GeneratorTransformer.js#newcode239 src/codegeneration/generator/GeneratorTransformer.js:239: // TODO: Look into if this code can be ...
11 years, 7 months ago (2013-03-15 16:21:58 UTC) #3
arv
LGTM https://codereview.appspot.com/7487046/diff/10002/src/codegeneration/generator/GeneratorTransformer.js File src/codegeneration/generator/GeneratorTransformer.js (right): https://codereview.appspot.com/7487046/diff/10002/src/codegeneration/generator/GeneratorTransformer.js#newcode238 src/codegeneration/generator/GeneratorTransformer.js:238: var $generatorWrap = this.runtimeInliner_.get('generatorWrap', no need to prefix ...
11 years, 7 months ago (2013-03-17 17:03:06 UTC) #4
usrbincc
https://codereview.appspot.com/7487046/diff/10002/src/codegeneration/generator/GeneratorTransformer.js File src/codegeneration/generator/GeneratorTransformer.js (right): https://codereview.appspot.com/7487046/diff/10002/src/codegeneration/generator/GeneratorTransformer.js#newcode238 src/codegeneration/generator/GeneratorTransformer.js:238: var $generatorWrap = this.runtimeInliner_.get('generatorWrap', On 2013/03/17 17:03:06, arv-chromium wrote: ...
11 years, 7 months ago (2013-03-18 18:24:59 UTC) #5
arv
LGTM Are we ready to land these? https://codereview.appspot.com/7487046/diff/20001/src/codegeneration/generator/GeneratorTransformer.js File src/codegeneration/generator/GeneratorTransformer.js (right): https://codereview.appspot.com/7487046/diff/20001/src/codegeneration/generator/GeneratorTransformer.js#newcode363 src/codegeneration/generator/GeneratorTransformer.js:363: * @param ...
11 years, 7 months ago (2013-03-18 18:59:55 UTC) #6
usrbincc
> Are we ready to land these? I think this patch series is ready to ...
11 years, 7 months ago (2013-03-18 20:03:44 UTC) #7
arv
11 years, 7 months ago (2013-03-18 20:19:25 UTC) #8
Submitted all the patches without any merge conflicts and all tests still
passes.

Thanks

Peter was adding TypeScript type annotation and he was going to add a
static type check pass. Adding runtime asserts is another option. I also
think those are valuable to be able to turn on for debug mode.


On Mon, Mar 18, 2013 at 4:03 PM, <usrbincc@yahoo.com> wrote:

>  Are we ready to land these?
>>
>
> I think this patch series is ready to go as long as long as you don't
> notice anything else. I'm pretty sure something will show up no matter
> what, though. (Gotten somewhat resigned to that)
>
> I'll go ahead and get the next issue (move main state machine code into
> separate function from try-catch) merged with the latest from here.
>
>
>
>
> https://codereview.appspot.**com/7487046/diff/20001/src/**
>
codegeneration/generator/**GeneratorTransformer.js<https://codereview.appspot.com/7487046/diff/20001/src/codegeneration/generator/GeneratorTransformer.js>
> File src/codegeneration/generator/**GeneratorTransformer.js (right):
>
> https://codereview.appspot.**com/7487046/diff/20001/src/**
>
codegeneration/generator/**GeneratorTransformer.js#**newcode363<https://codereview.appspot.com/7487046/diff/20001/src/codegeneration/generator/GeneratorTransformer.js#newcode363>
> src/codegeneration/generator/**GeneratorTransformer.js:363: * @param
> {RuntimeInliner} runtimeInliner
>
>> Peter started this work... I'm looking forward to progress in that
>>
> area.
>
> Compilers has always sort of been an area of interest, but it's never
> been my strong point. Not 100% sure which area you're referring to, but
> if you mean making the compiler use the JSDoc for type-checking, then
> I wouldn't know where to start. It'd theoretically be trivial to turn
> the JSDoc into runtime checks, though.
>
>   /**
>    * @param {number} a
>    * @param {number} b
>    * @return {string}
>    */
>   function addAndReturnString(a, b) {
>     return String(a + b);
>   }
>
>   // generated code
>   function addAndReturnString(a, b) {
>     assert(typeof a === 'number');
>     assert(typeof b === 'number');
>     $ret = String(a + b);
>     assert(typeof $ret === 'string');
>     return $ret;
>   }
>
>
https://codereview.appspot.**com/7487046/<https://codereview.appspot.com/7487...
>



-- 
erik
Sign in to reply to this message.

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