When JS scripts compiles into a dll, the Start, Update, etc methods all are 'overrides'? and... there's also a 'Main' method?

So I was messing with manual compilation a bit, and compiled a simple JS script into a dll:

TestJs.js

#pragma strict

function Update() { }
function Start() { }

I looked at the generated dll, and was quite surprised…

28024-compile.png

I’m not a JS dude, so I could be missing something simple. But, what are we ‘overriding’, and who the hell is this “Main”?!

But, what are we ‘overriding’, and who the hell is this “Main”?!

You’re overriding the base implementation that exists in MonoBehavior in favor of your implementation, the state machine needs to have some consistency when calling methods.

Main is just a another method available, probably not documented due to UT either not expecting a user to override it typically or it has a very particular execution path that is generally covered by Awake/Start.