Libraryless. Click here for Pure Java version (2897L/20K/66K).
1 | !7 |
2 | |
3 | sS extensionCode = [[ |
4 | sclass existing {
|
5 | svoid bla {
|
6 | print("I was overwritten");
|
7 | } |
8 | } |
9 | |
10 | sclass ext {
|
11 | svoid yo {
|
12 | print("Yo!");
|
13 | existing.bla(); |
14 | } |
15 | } |
16 | ]]; |
17 | |
18 | sclass existing {
|
19 | svoid bla {
|
20 | print("I exist");
|
21 | } |
22 | } |
23 | |
24 | p {
|
25 | liveWire(extensionCode); |
26 | call(getClass("main$ext"), "yo");
|
27 | } |
Began life as a copy of #1008731
download show line numbers debug dex old transpilations
Travelled to 13 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #1008733 |
| Snippet name: | Test if live-wiring overwrites existing classes (it doesn't) |
| Eternal ID of this version: | #1008733/4 |
| Text MD5: | a8521a07ed787db4ce82633284e1d8e6 |
| Transpilation MD5: | 9ef0957fde977bb8832ba6528907ed06 |
| Author: | stefan |
| Category: | javax |
| Type: | JavaX source code |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2017-05-31 01:34:03 |
| Source code size: | 349 bytes / 27 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 694 / 853 |
| Version history: | 3 change(s) |
| Referenced in: | [show references] |