Commit f6ba0bd
zhenyanzhang
Update on "[ExecuTorch][#10375] Add
#10375
# Context
This issue is a step of #9638.
In #9638, we want to have `extension.Module` as the single source of implementation in `pybindings`, which means that `pybindings.PyModule` should use `extension.Module` rather than its own `pybindings.Module`.
The issue is that `pybindings.PyModule` is dependent on the `method` getter from `pybindings.Module`, which `extension.Module` do not have. Since we don't want to expose `method` getter in `extension.Module`, we have to protect the getter, wrap the functions that is dependent on it and use the protected getter there, ultimately decouple `pybindings` from a `method` getter.
# Proposal
Now that we have a protected `method` getter, we can introduce a `extension.BundledModule`, a child class inheriting `extension.Module` which wraps up bundled program logic that is dependent on the `method` getter.
Differential Revision: [D73564125](https://our.internmc.facebook.com/intern/diff/D73564125/)
[ghstack-poisoned]extension.BundledModule to Wrap extension.Module with Bundled Program Logic"1 parent 5feb8d5 commit f6ba0bd
1 file changed
+9
-10
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
531 | 531 | | |
532 | 532 | | |
533 | 533 | | |
534 | | - | |
535 | | - | |
| 534 | + | |
| 535 | + | |
536 | 536 | | |
537 | | - | |
538 | | - | |
| 537 | + | |
539 | 538 | | |
540 | 539 | | |
541 | | - | |
542 | | - | |
| 540 | + | |
| 541 | + | |
543 | 542 | | |
544 | | - | |
545 | | - | |
| 543 | + | |
| 544 | + | |
546 | 545 | | |
547 | 546 | | |
548 | 547 | | |
| |||
551 | 550 | | |
552 | 551 | | |
553 | 552 | | |
554 | | - | |
| 553 | + | |
555 | 554 | | |
556 | | - | |
| 555 | + | |
557 | 556 | | |
558 | 557 | | |
559 | 558 | | |
| |||
0 commit comments