ScriptRuntimeApiImpl wasm compatibility fixed by gleblebedev · Pull Request #601 · rbfx/rbfx · GitHub
Skip to content

ScriptRuntimeApiImpl wasm compatibility fixed - #601

Open
gleblebedev wants to merge 5 commits into
rbfx:masterfrom
gleblebedev:gl/Wasm_ScriptRuntimeApiImpl
Open

gleblebedev wants to merge 5 commits into
rbfx:masterfrom
gleblebedev:gl/Wasm_ScriptRuntimeApiImpl

Conversation

@gleblebedev

Copy link
Copy Markdown
Contributor

ScriptRuntimeApiImpl type failed to initialize when running in web assembly because there is no assembly available there.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Doesn't this call throw an exception? Strings default to null, so in wasm they wont be set and this call tries to use ProgramDirectory. Either InstallAssemblyLoader needs to be not called or it needs to be modified to correctly work on wasm. I have no idea if we can have multiple C# DLLs on wasm platform and whether loading a DLL dynamically makes sense.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It throws exception if there is no check. Also I didn't find any code that reads the field...

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Like i said InstallAssemblyLoader tries to use ProgramDirectory so there would be an exception whenever ScriptRuntimeApiImpl is constructed.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants