Skip to content

Refactor module element related functions (NFC)#2550

Merged
aheejin merged 2 commits intoWebAssembly:masterfrom
aheejin:refactor_module
Dec 23, 2019
Merged

Refactor module element related functions (NFC)#2550
aheejin merged 2 commits intoWebAssembly:masterfrom
aheejin:refactor_module

Conversation

@aheejin
Copy link
Copy Markdown
Member

@aheejin aheejin commented Dec 21, 2019

This does something similar to #2489 for more functions, removing
boilerplate code for each module element using template functions.

@aheejin aheejin requested review from kripken and tlively December 21, 2019 03:32
This does something similar to WebAssembly#2489 for more functions, removing
boilerplate code for each module element using template functions.
Copy link
Copy Markdown
Member

@kripken kripken left a comment

Choose a reason for hiding this comment

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

Nice!

Comment thread src/wasm/wasm.cpp Outdated
Fatal() << "Module::getExport: " << name << " does not exist";
template<typename Map>
typename Map::mapped_type&
getModuleElement(Map& m, Name name, std::string funcName) {
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.

perhaps const std::string&?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Done

@aheejin aheejin merged commit f42d8f6 into WebAssembly:master Dec 23, 2019
@aheejin aheejin deleted the refactor_module branch December 23, 2019 22:55
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