Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow addInitializer in field decorator context #16132

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/babel-helpers/src/helpers-generated.ts
Expand Up @@ -39,7 +39,7 @@ export default Object.freeze({
),
applyDecs2305: helper(
"7.21.0",
'import checkInRHS from"checkInRHS";function _bindPropCall(e,t){return function(r,a){return e[t].call(r,a)}}function createAddInitializerMethod(e,t){return function(r){if(t.v)throw new Error("attempted to call addInitializer after decoration was finished");assertCallable(r,"An initializer",!0),e.push(r)}}function memberDec(e,t,r,a,n,i,o,s,l,c,u){function assertInstanceIfPrivate(e){return function(t,r){if(!c(t))throw new TypeError("Attempted to access private element on non-instance");return e(t,r)}}var f,d,p={kind:["field","accessor","method","getter","setter","field"][i],name:s?"#"+r:r,static:o,private:s,metadata:u},v={v:!1};if(0!==i&&(p.addInitializer=createAddInitializerMethod(n,v)),s||0!==i&&2!==i)if(2===i)f=assertInstanceIfPrivate((function(){return a.value}));else{var h=0===i||1===i;(h||3===i)&&(f=_bindPropCall(a,"get"),s&&(f=assertInstanceIfPrivate(f))),(h||4===i)&&(d=_bindPropCall(a,"set"),s&&(d=assertInstanceIfPrivate(d)))}else f=function(e){return e[r]},0===i&&(d=function(e,t){e[r]=t});var m=s?c.bind():function(e){return r in e},b=p.access={has:m};f&&(b.get=f),d&&(b.set=d);try{return e.call(t,l,p)}finally{v.v=!0}}function assertCallable(e,t,r){if("function"!=typeof e&&(r||void 0!==e))throw new TypeError(t+" must be a function")}function assertValidReturnValue(e,t){var r=typeof t;if(1===e){if("object"!==r||!t)throw new TypeError("accessor decorators must return an object with get, set, or init properties or void 0");assertCallable(t.get,"accessor.get"),assertCallable(t.set,"accessor.set"),assertCallable(t.init,"accessor.init")}else if("function"!==r)throw new TypeError((0===e?"field":5===e?"class":"method")+" decorators must return a function or void 0")}function applyMemberDec(e,t,r,a,n,i,o,s,l,c,u){var f,d,p,v,h=r[0],m=r[3];a||Array.isArray(h)||(h=[h]),s?f=0===i||1===i?{get:function(){return m(this)},set:function(e){r[4](this,e)}}:3===i?{get:m}:4===i?{set:m}:{value:m}:0!==i&&(f=Object.getOwnPropertyDescriptor(t,n)),1===i?p={get:f.get,set:f.set}:2===i?p=f.value:3===i?p=f.get:4===i&&(p=f.set);for(var b=a?2:1,y=h.length-1;y>=0;y-=b){var g;if(void 0!==(v=memberDec(h[y],a?h[y-1]:void 0,n,f,l,i,o,s,p,c,u)))assertValidReturnValue(i,v),0===i?g=v:1===i?(g=v.init,p={get:v.get||p.get,set:v.set||p.set}):p=v,void 0!==g&&(void 0===d?d=g:"function"==typeof d?d=[d,g]:d.push(g))}if(0===i||1===i){if(void 0===d)d=function(e,t){return t};else if("function"!=typeof d){var I=d;d=function(e,t){for(var r=t,a=I.length-1;a>=0;a--)r=I[a].call(e,r);return r}}else{var w=d;d=d.call.bind(w)}e.push(d)}0!==i&&(1===i?(f.get=p.get,f.set=p.set):2===i?f.value=p:3===i?f.get=p:4===i&&(f.set=p),s?1===i?e.push(_bindPropCall(f,"get"),_bindPropCall(f,"set")):e.push(2===i?p:Function.call.bind(p)):Object.defineProperty(t,n,f))}function applyMemberDecs(e,t,r,a){var n,i,o,s=[],l=new Map,c=new Map;function pushInitializers(e){e&&s.push((function(t){for(var r=0;r<e.length;r++)e[r].call(t);return t}))}for(var u=0;u<t.length;u++){var f=t[u];if(Array.isArray(f)){var d,p,v=f[1],h=f[2],m=f.length>3,b=16&v,y=!!(8&v),g=r;if(v&=7,y?(d=e,0!==v&&(p=i=i||[]),m&&!o&&(o=function(t){return checkInRHS(t)===e}),g=o):(d=e.prototype,0!==v&&(p=n=n||[])),0!==v&&!m){var I=y?c:l,w=I.get(h)||0;if(!0===w||3===w&&4!==v||4===w&&3!==v)throw new Error("Attempted to decorate a public method/accessor that has the same name as a previously decorated public method/accessor. This is not currently supported by the decorators plugin. Property name was: "+h);I.set(h,!(!w&&v>2)||v)}applyMemberDec(s,d,f,b,h,v,y,m,p,g,a)}}return pushInitializers(n),pushInitializers(i),s}function applyClassDecs(e,t,r,a){if(t.length){for(var n=[],i=e,o=e.name,s=r?2:1,l=t.length-1;l>=0;l-=s){var c={v:!1};try{var u=t[l].call(r?t[l-1]:void 0,i,{kind:"class",name:o,addInitializer:createAddInitializerMethod(n,c),metadata:a})}finally{c.v=!0}void 0!==u&&(assertValidReturnValue(5,u),i=u)}return[defineMetadata(i,a),function(){for(var e=0;e<n.length;e++)n[e].call(i)}]}}function defineMetadata(e,t){return Object.defineProperty(e,Symbol.metadata||Symbol.for("Symbol.metadata"),{configurable:!0,enumerable:!0,value:t})}export default function applyDecs2305(e,t,r,a,n,i){if(arguments.length>=6)var o=i[Symbol.metadata||Symbol.for("Symbol.metadata")];var s=Object.create(void 0===o?null:o),l=applyMemberDecs(e,t,n,s);return r.length||defineMetadata(e,s),{e:l,get c(){return applyClassDecs(e,r,a,s)}}}',
'import checkInRHS from"checkInRHS";function _bindPropCall(e,t){return function(r,a){return e[t].call(r,a)}}function createAddInitializerMethod(e,t){return function(r){if(t.v)throw new Error("attempted to call addInitializer after decoration was finished");assertCallable(r,"An initializer",!0),e.push(r)}}function memberDec(e,t,r,a,n,i,o,s,l,c,u){function assertInstanceIfPrivate(e){return function(t,r){if(!c(t))throw new TypeError("Attempted to access private element on non-instance");return e(t,r)}}var f,d,p={v:!1},v={kind:["field","accessor","method","getter","setter","field"][i],name:s?"#"+r:r,static:o,private:s,metadata:u,addInitializer:createAddInitializerMethod(n,p)};if(s||0!==i&&2!==i)if(2===i)f=assertInstanceIfPrivate((function(){return a.value}));else{var h=0===i||1===i;(h||3===i)&&(f=_bindPropCall(a,"get"),s&&(f=assertInstanceIfPrivate(f))),(h||4===i)&&(d=_bindPropCall(a,"set"),s&&(d=assertInstanceIfPrivate(d)))}else f=function(e){return e[r]},0===i&&(d=function(e,t){e[r]=t});var m=s?c.bind():function(e){return r in e},b=v.access={has:m};f&&(b.get=f),d&&(b.set=d);try{return e.call(t,l,v)}finally{p.v=!0}}function assertCallable(e,t,r){if("function"!=typeof e&&(r||void 0!==e))throw new TypeError(t+" must be a function")}function assertValidReturnValue(e,t){var r=typeof t;if(1===e){if("object"!==r||!t)throw new TypeError("accessor decorators must return an object with get, set, or init properties or void 0");assertCallable(t.get,"accessor.get"),assertCallable(t.set,"accessor.set"),assertCallable(t.init,"accessor.init")}else if("function"!==r)throw new TypeError((0===e?"field":5===e?"class":"method")+" decorators must return a function or void 0")}function applyMemberDec(e,t,r,a,n,i,o,s,l,c,u){var f,d,p,v,h=r[0],m=r[3];a||Array.isArray(h)||(h=[h]),s?f=0===i||1===i?{get:function(){return m(this)},set:function(e){r[4](this,e)}}:3===i?{get:m}:4===i?{set:m}:{value:m}:0!==i&&(f=Object.getOwnPropertyDescriptor(t,n)),1===i?p={get:f.get,set:f.set}:2===i?p=f.value:3===i?p=f.get:4===i&&(p=f.set);for(var b=a?2:1,y=h.length-1;y>=0;y-=b){var g;if(void 0!==(v=memberDec(h[y],a?h[y-1]:void 0,n,f,l,i,o,s,p,c,u)))assertValidReturnValue(i,v),0===i?g=v:1===i?(g=v.init,p={get:v.get||p.get,set:v.set||p.set}):p=v,void 0!==g&&(void 0===d?d=g:"function"==typeof d?d=[d,g]:d.push(g))}if(0===i||1===i){if(void 0===d)d=function(e,t){return t};else if("function"!=typeof d){var I=d;d=function(e,t){for(var r=t,a=I.length-1;a>=0;a--)r=I[a].call(e,r);return r}}else{var w=d;d=d.call.bind(w)}e.push(d)}0!==i&&(1===i?(f.get=p.get,f.set=p.set):2===i?f.value=p:3===i?f.get=p:4===i&&(f.set=p),s?1===i?e.push(_bindPropCall(f,"get"),_bindPropCall(f,"set")):e.push(2===i?p:Function.call.bind(p)):Object.defineProperty(t,n,f))}function applyMemberDecs(e,t,r,a){var n,i,o,s=[],l=new Map,c=new Map;function pushInitializers(e){e&&s.push((function(t){for(var r=0;r<e.length;r++)e[r].call(t);return t}))}for(var u=0;u<t.length;u++){var f=t[u];if(Array.isArray(f)){var d,p,v=f[1],h=f[2],m=f.length>3,b=16&v,y=!!(8&v),g=r;if(v&=7,y?(d=e,p=i=i||[],m&&!o&&(o=function(t){return checkInRHS(t)===e}),g=o):(d=e.prototype,p=n=n||[]),0!==v&&!m){var I=y?c:l,w=I.get(h)||0;if(!0===w||3===w&&4!==v||4===w&&3!==v)throw new Error("Attempted to decorate a public method/accessor that has the same name as a previously decorated public method/accessor. This is not currently supported by the decorators plugin. Property name was: "+h);I.set(h,!(!w&&v>2)||v)}applyMemberDec(s,d,f,b,h,v,y,m,p,g,a)}}return pushInitializers(n),pushInitializers(i),s}function applyClassDecs(e,t,r,a){if(t.length){for(var n=[],i=e,o=e.name,s=r?2:1,l=t.length-1;l>=0;l-=s){var c={v:!1};try{var u=t[l].call(r?t[l-1]:void 0,i,{kind:"class",name:o,addInitializer:createAddInitializerMethod(n,c),metadata:a})}finally{c.v=!0}void 0!==u&&(assertValidReturnValue(5,u),i=u)}return[defineMetadata(i,a),function(){for(var e=0;e<n.length;e++)n[e].call(i)}]}}function defineMetadata(e,t){return Object.defineProperty(e,Symbol.metadata||Symbol.for("Symbol.metadata"),{configurable:!0,enumerable:!0,value:t})}export default function applyDecs2305(e,t,r,a,n,i){if(arguments.length>=6)var o=i[Symbol.metadata||Symbol.for("Symbol.metadata")];var s=Object.create(void 0===o?null:o),l=applyMemberDecs(e,t,n,s);return r.length||defineMetadata(e,s),{e:l,get c(){return applyClassDecs(e,r,a,s)}}}',
),
asyncGeneratorDelegate: helper(
"7.0.0-beta.0",
Expand Down
28 changes: 10 additions & 18 deletions packages/babel-helpers/src/helpers/applyDecs2305.ts
Expand Up @@ -88,6 +88,7 @@ function memberDec(
};
}

var decoratorFinishedRef = { v: false };
var ctx: DecoratorContext = {
kind: ["field", "accessor", "method", "getter", "setter", "field"][
kind
Expand All @@ -97,16 +98,11 @@ function memberDec(
static: isStatic,
private: isPrivate,
metadata: metadata,
};

var decoratorFinishedRef = { v: false };

if (kind !== PROP_KIND.FIELD) {
ctx.addInitializer = createAddInitializerMethod(
addInitializer: createAddInitializerMethod(
initializers,
decoratorFinishedRef,
);
}
),
};

var get, set;
if (!isPrivate && (kind === PROP_KIND.FIELD || kind === PROP_KIND.METHOD)) {
Expand Down Expand Up @@ -396,11 +392,9 @@ function applyMemberDecs(

if (isStatic) {
base = Class;
// initialize staticInitializers when we see a non-field static member
if (kind !== PROP_KIND.FIELD) {
staticInitializers = staticInitializers || [];
initializers = staticInitializers;
}
// initialize staticInitializers when we see a static member
staticInitializers = staticInitializers || [];
initializers = staticInitializers;
if (isPrivate && !staticBrand) {
staticBrand = function (_: any) {
return checkInRHS(_) === Class;
Expand All @@ -409,11 +403,9 @@ function applyMemberDecs(
hasPrivateBrand = staticBrand;
} else {
base = Class.prototype;
// initialize protoInitializers when we see a non-field member
if (kind !== PROP_KIND.FIELD) {
protoInitializers = protoInitializers || [];
initializers = protoInitializers;
}
// initialize protoInitializers when we see a non-static member
protoInitializers = protoInitializers || [];
initializers = protoInitializers;
}

if (kind !== PROP_KIND.FIELD && !isPrivate) {
Expand Down
Expand Up @@ -32,7 +32,7 @@ expect(aContext.name).toBe('#a');
expect(aContext.kind).toBe('field');
expect(aContext.static).toBe(false);
expect(aContext.private).toBe(true);
expect(typeof aContext.addInitializer).toBe('undefined');
expect(typeof aContext.addInitializer).toBe('function');

expect(bContext.access.get(foo)).toBe(124);
bContext.access.set(foo, 123);
Expand All @@ -41,4 +41,4 @@ expect(bContext.name).toBe('#b');
expect(bContext.kind).toBe('field');
expect(bContext.static).toBe(false);
expect(bContext.private).toBe(true);
expect(typeof aContext.addInitializer).toBe('undefined');
expect(typeof aContext.addInitializer).toBe('function');
Expand Up @@ -40,7 +40,7 @@ expect(aContext.name).toBe('a');
expect(aContext.kind).toBe('field');
expect(aContext.static).toBe(false);
expect(aContext.private).toBe(false);
expect(typeof aContext.addInitializer).toBe('undefined');
expect(typeof aContext.addInitializer).toBe('function');
expect(foo.hasOwnProperty('a')).toBe(true);
expect(Foo.prototype.hasOwnProperty('a')).toBe(false);

Expand All @@ -51,7 +51,7 @@ expect(bContext.name).toBe('b');
expect(bContext.kind).toBe('field');
expect(bContext.static).toBe(false);
expect(bContext.private).toBe(false);
expect(typeof bContext.addInitializer).toBe('undefined');
expect(typeof bContext.addInitializer).toBe('function');
expect(foo.hasOwnProperty('b')).toBe(true);
expect(Foo.prototype.hasOwnProperty('b')).toBe(false);

Expand All @@ -62,6 +62,6 @@ expect(cContext.name).toBe('c');
expect(cContext.kind).toBe('field');
expect(cContext.static).toBe(false);
expect(cContext.private).toBe(false);
expect(typeof cContext.addInitializer).toBe('undefined');
expect(typeof cContext.addInitializer).toBe('function');
expect(foo.hasOwnProperty('c')).toBe(true);
expect(Foo.prototype.hasOwnProperty('c')).toBe(false);
Expand Up @@ -30,7 +30,7 @@ expect(aContext.name).toBe('#a');
expect(aContext.kind).toBe('field');
expect(aContext.static).toBe(true);
expect(aContext.private).toBe(true);
expect(typeof aContext.addInitializer).toBe('undefined');
expect(typeof aContext.addInitializer).toBe('function');

expect(bContext.access.get(Foo)).toBe(124);
bContext.access.set(Foo, 123);
Expand All @@ -39,4 +39,4 @@ expect(bContext.name).toBe('#b');
expect(bContext.kind).toBe('field');
expect(bContext.static).toBe(true);
expect(bContext.private).toBe(true);
expect(typeof aContext.addInitializer).toBe('undefined');
expect(typeof aContext.addInitializer).toBe('function');
Expand Up @@ -38,7 +38,7 @@ expect(aContext.name).toBe('a');
expect(aContext.kind).toBe('field');
expect(aContext.static).toBe(true);
expect(aContext.private).toBe(false);
expect(typeof aContext.addInitializer).toBe('undefined');
expect(typeof aContext.addInitializer).toBe('function');
expect(Foo.hasOwnProperty('a')).toBe(true);

expect(Foo.b).toBe(124);
Expand All @@ -48,7 +48,7 @@ expect(bContext.name).toBe('b');
expect(bContext.kind).toBe('field');
expect(bContext.static).toBe(true);
expect(bContext.private).toBe(false);
expect(typeof bContext.addInitializer).toBe('undefined');
expect(typeof bContext.addInitializer).toBe('function');
expect(Foo.hasOwnProperty('b')).toBe(true);

expect(Foo.c).toBe(457);
Expand All @@ -58,5 +58,5 @@ expect(cContext.name).toBe('c');
expect(cContext.kind).toBe('field');
expect(cContext.static).toBe(true);
expect(cContext.private).toBe(false);
expect(typeof cContext.addInitializer).toBe('undefined');
expect(typeof cContext.addInitializer).toBe('function');
expect(Foo.hasOwnProperty('c')).toBe(true);
@@ -0,0 +1,211 @@
const log = [];
const classDec1 = (cls, ctxClass) => {
log.push("c2");
ctxClass.addInitializer(() => log.push("c5"));
ctxClass.addInitializer(() => log.push("c6"));
};
const classDec2 = (cls, ctxClass) => {
log.push("c1");
ctxClass.addInitializer(() => log.push("c3"));
ctxClass.addInitializer(() => log.push("c4"));
};
const methodDec1 = (fn, ctxMethod) => {
log.push("m2");
ctxMethod.addInitializer(() => log.push("m5"));
ctxMethod.addInitializer(() => log.push("m6"));
};
const methodDec2 = (fn, ctxMethod) => {
log.push("m1");
ctxMethod.addInitializer(() => log.push("m3"));
ctxMethod.addInitializer(() => log.push("m4"));
};
const staticMethodDec1 = (fn, ctxStaticMethod) => {
log.push("M2");
ctxStaticMethod.addInitializer(() => log.push("M5"));
ctxStaticMethod.addInitializer(() => log.push("M6"));
};
const staticMethodDec2 = (fn, ctxStaticMethod) => {
log.push("M1");
ctxStaticMethod.addInitializer(() => log.push("M3"));
ctxStaticMethod.addInitializer(() => log.push("M4"));
};
const fieldDec1 = (value, ctxField) => {
log.push("f2");
ctxField.addInitializer(() => log.push("f5"));
ctxField.addInitializer(() => log.push("f6"));
return () => {
log.push("f7");
};
};
const fieldDec2 = (value, ctxField) => {
log.push("f1");
ctxField.addInitializer(() => log.push("f3"));
ctxField.addInitializer(() => log.push("f4"));
return () => {
log.push("f8");
};
};
const staticFieldDec1 = (value, ctxStaticField) => {
log.push("F2");
ctxStaticField.addInitializer(() => log.push("F5"));
ctxStaticField.addInitializer(() => log.push("F6"));
return () => {
log.push("F7");
};
};
const staticFieldDec2 = (value, ctxStaticField) => {
log.push("F1");
ctxStaticField.addInitializer(() => log.push("F3"));
ctxStaticField.addInitializer(() => log.push("F4"));
return () => {
log.push("F8");
};
};
const getterDec1 = (fn, ctxGetter) => {
log.push("g2");
ctxGetter.addInitializer(() => log.push("g5"));
ctxGetter.addInitializer(() => log.push("g6"));
};
const getterDec2 = (fn, ctxGetter) => {
log.push("g1");
ctxGetter.addInitializer(() => log.push("g3"));
ctxGetter.addInitializer(() => log.push("g4"));
};
const staticGetterDec1 = (fn, ctxStaticGetter) => {
log.push("G2");
ctxStaticGetter.addInitializer(() => log.push("G5"));
ctxStaticGetter.addInitializer(() => log.push("G6"));
};
const staticGetterDec2 = (fn, ctxStaticGetter) => {
log.push("G1");
ctxStaticGetter.addInitializer(() => log.push("G3"));
ctxStaticGetter.addInitializer(() => log.push("G4"));
};
const setterDec1 = (fn, ctxSetter) => {
log.push("s2");
ctxSetter.addInitializer(() => log.push("s5"));
ctxSetter.addInitializer(() => log.push("s6"));
};
const setterDec2 = (fn, ctxSetter) => {
log.push("s1");
ctxSetter.addInitializer(() => log.push("s3"));
ctxSetter.addInitializer(() => log.push("s4"));
};
const staticSetterDec1 = (fn, ctxStaticSetter) => {
log.push("S2");
ctxStaticSetter.addInitializer(() => log.push("S5"));
ctxStaticSetter.addInitializer(() => log.push("S6"));
};
const staticSetterDec2 = (fn, ctxStaticSetter) => {
log.push("S1");
ctxStaticSetter.addInitializer(() => log.push("S3"));
ctxStaticSetter.addInitializer(() => log.push("S4"));
};
const accessorDec1 = (target, ctxAccessor) => {
log.push("a2");
ctxAccessor.addInitializer(() => log.push("a5"));
ctxAccessor.addInitializer(() => log.push("a6"));
return { init() {
log.push("a7");
} };
};
const accessorDec2 = (target, ctxAccessor) => {
log.push("a1");
ctxAccessor.addInitializer(() => log.push("a3"));
ctxAccessor.addInitializer(() => log.push("a4"));
return { init() {
log.push("a8");
} };
};
const staticAccessorDec1 = (target, ctxStaticAccessor) => {
log.push("A2");
ctxStaticAccessor.addInitializer(() => log.push("A5"));
ctxStaticAccessor.addInitializer(() => log.push("A6"));
return { init() {
log.push("A7");
} };
};
const staticAccessorDec2 = (target, ctxStaticAccessor) => {
log.push("A1");
ctxStaticAccessor.addInitializer(() => log.push("A3"));
ctxStaticAccessor.addInitializer(() => log.push("A4"));
return { init() {
log.push("A8");
} };
};
log.push("start");
@classDec1
@classDec2
class Foo extends (log.push("extends"), Object) {
static {
log.push("static:start");
}
constructor() {
log.push("ctor:start");
super();
log.push("ctor:end");
}
@methodDec1
@methodDec2
method() {
}
@staticMethodDec1
@staticMethodDec2
static method() {
}
@fieldDec1
@fieldDec2
field;
@staticFieldDec1
@staticFieldDec2
static field;
@getterDec1
@getterDec2
get getter() {
return;
}
@staticGetterDec1
@staticGetterDec2
static get getter() {
return;
}
@setterDec1
@setterDec2
set setter(x) {
}
@staticSetterDec1
@staticSetterDec2
static set getter(x) {
}
@accessorDec1
@accessorDec2
accessor accessor;
@staticAccessorDec1
@staticAccessorDec2
static accessor accessor;
static {
log.push("static:end");
}
}
log.push("after");
new Foo();
log.push("end");
expect(log + "").toEqual(
'start,extends,' +
'M1,M2,G1,G2,S1,S2,A1,A2,' + // For each element e of staticElements if e.[[Kind]] is not field
'm1,m2,g1,g2,s1,s2,a1,a2,' + // For each element e of instanceElements if e.[[Kind]] is not field
'F1,F2,' + // For each element e of staticElements if e.[[Kind]] is field
'f1,f2,' + // For each element e of instanceElements if e.[[Kind]] is field
'c1,c2,' + // ApplyDecoratorsToClassDefinition
'M3,M4,M5,M6,G3,G4,G5,G6,S3,S4,S5,S6,A3,A4,A5,A6,F3,F4,F5,F6,' + // staticExtraInitializers
'static:start,' + // staticElements
'F7,F8,A7,A8,' + // InitializeFieldOrAccessor
'static:end,' + // staticElements
'c3,c4,c5,c6,' + // classExtraInitializers
'after,' +
'ctor:start,' +
'm3,m4,m5,m6,g3,g4,g5,g6,s3,s4,s5,s6,a3,a4,a5,a6,f3,f4,f5,f6,' + // instanceExtraInitializers
'f7,f8,a7,a8,' + // InitializeFieldOrAccessor
'ctor:end,' +
'end'
);