You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// This file is a generated precompile contract config with stubbed abstract functions.
9
9
// The file is generated by a template. Please inspect every code and comment in this file before use.
10
10
11
-
// There are some must-be-done changes waiting in the file. Each area requiring you to add your code is marked with CUSTOM CODE to make them easy to find and modify.
12
-
// Additionally there are other files you need to edit to activate your precompile.
13
-
// These areas are highlighted with comments "ADD YOUR PRECOMPILE HERE".
14
-
// For testing take a look at other precompile tests in contract_test.go and config_test.go in other precompile folders.
15
-
// See the tutorial in https://docs.avax.network/subnets/hello-world-precompile-tutorial for more information about precompile development.
16
-
17
-
/* General guidelines for precompile development:
18
-
1- Read the comment and set a suitable contract address in generated module.go. E.g:
2- Set a suitable config key in generated module.go. E.g: "yourPrecompileConfig"
21
-
3- It is recommended to only modify code in the highlighted areas marked with "CUSTOM CODE STARTS HERE". Typically, custom codes are required in only those areas.
22
-
Modifying code outside of these areas should be done with caution and with a deep understanding of how these changes may impact the EVM.
23
-
4- Set gas costs in generated contract.go
24
-
5- Add your config unit tests under generated package config_test.go
25
-
6- Add your contract unit tests undertgenerated package contract_test.go
26
-
7- Additionally you can add a full-fledged VM test for your precompile under plugin/vm/vm_test.go. See existing precompile tests for examples.
27
-
8- Add your solidity interface and test contract to contract-examples/contracts
28
-
9- Write solidity tests for your precompile in contract-examples/test
29
-
10- Create your genesis with your precompile enabled in tests/e2e/genesis/
30
-
11- Create e2e test for your solidity test in tests/e2e/solidity/suites.go
31
-
12- Run your e2e precompile Solidity tests with 'E2E=true ./scripts/run.sh'
// This file is a generated precompile contract config with stubbed abstract functions.
26
26
// The file is generated by a template. Please inspect every code and comment in this file before use.
27
27
28
-
// There are some must-be-done changes waiting in the file. Each area requiring you to add your code is marked with CUSTOM CODE to make them easy to find and modify.
29
-
// Additionally there are other files you need to edit to activate your precompile.
30
-
// These areas are highlighted with comments "ADD YOUR PRECOMPILE HERE".
31
-
// For testing take a look at other precompile tests in contract_test.go and config_test.go in other precompile folders.
32
-
// See the tutorial in https://docs.avax.network/subnets/hello-world-precompile-tutorial for more information about precompile development.
33
-
34
-
/* General guidelines for precompile development:
35
-
1- Read the comment and set a suitable contract address in generated module.go. E.g:
2- Set a suitable config key in generated module.go. E.g: "yourPrecompileConfig"
38
-
3- It is recommended to only modify code in the highlighted areas marked with "CUSTOM CODE STARTS HERE". Typically, custom codes are required in only those areas.
39
-
Modifying code outside of these areas should be done with caution and with a deep understanding of how these changes may impact the EVM.
40
-
4- Set gas costs in generated contract.go
41
-
5- Add your config unit tests under generated package config_test.go
42
-
6- Add your contract unit tests undertgenerated package contract_test.go
43
-
7- Additionally you can add a full-fledged VM test for your precompile under plugin/vm/vm_test.go. See existing precompile tests for examples.
44
-
8- Add your solidity interface and test contract to contract-examples/contracts
45
-
9- Write solidity tests for your precompile in contract-examples/test
46
-
10- Create your genesis with your precompile enabled in tests/e2e/genesis/
47
-
11- Create e2e test for your solidity test in tests/e2e/solidity/suites.go
48
-
12- Run your e2e precompile Solidity tests with 'E2E=true ./scripts/run.sh'
// This file is a generated precompile contract config with stubbed abstract functions.
9
9
// The file is generated by a template. Please inspect every code and comment in this file before use.
10
10
11
-
// There are some must-be-done changes waiting in the file. Each area requiring you to add your code is marked with CUSTOM CODE to make them easy to find and modify.
12
-
// Additionally there are other files you need to edit to activate your precompile.
13
-
// These areas are highlighted with comments "ADD YOUR PRECOMPILE HERE".
14
-
// For testing take a look at other precompile tests in contract_test.go and config_test.go in other precompile folders.
15
-
// See the tutorial in https://docs.avax.network/subnets/hello-world-precompile-tutorial for more information about precompile development.
16
-
17
-
/* General guidelines for precompile development:
18
-
1- Read the comment and set a suitable contract address in generated module.go. E.g:
2- Set a suitable config key in generated module.go. E.g: "yourPrecompileConfig"
21
-
3- It is recommended to only modify code in the highlighted areas marked with "CUSTOM CODE STARTS HERE". Typically, custom codes are required in only those areas.
22
-
Modifying code outside of these areas should be done with caution and with a deep understanding of how these changes may impact the EVM.
23
-
4- Set gas costs in generated contract.go
24
-
5- Add your config unit tests under generated package config_test.go
25
-
6- Add your contract unit tests undertgenerated package contract_test.go
26
-
7- Additionally you can add a full-fledged VM test for your precompile under plugin/vm/vm_test.go. See existing precompile tests for examples.
27
-
8- Add your solidity interface and test contract to contract-examples/contracts
28
-
9- Write solidity tests for your precompile in contract-examples/test
29
-
10- Create your genesis with your precompile enabled in tests/e2e/genesis/
30
-
11- Create e2e test for your solidity test in tests/e2e/solidity/suites.go
31
-
12- Run your e2e precompile Solidity tests with 'E2E=true ./scripts/run.sh'
There are some must-be-done changes waiting in the generated file. Each area requiring you to add your code is marked with CUSTOM CODE to make them easy to find and modify.
2
+
Additionally there are other files you need to edit to activate your precompile.
3
+
These areas are highlighted with comments "ADD YOUR PRECOMPILE HERE".
4
+
For testing take a look at other precompile tests in contract_test.go and config_test.go in other precompile folders.
5
+
See the tutorial in <https://docs.avax.network/subnets/hello-world-precompile-tutorial> for more information about precompile development.
6
+
7
+
General guidelines for precompile development:
8
+
1- Set a suitable config key in generated module.go. E.g: "yourPrecompileConfig"
9
+
2- Read the comment and set a suitable contract address in generated module.go. E.g:
3- It is recommended to only modify code in the highlighted areas marked with "CUSTOM CODE STARTS HERE". Typically, custom codes are required in only those areas.
12
+
Modifying code outside of these areas should be done with caution and with a deep understanding of how these changes may impact the EVM.
13
+
4- Set gas costs in generated contract.go
14
+
5- Force import your precompile package in precompile/registry/registry.go
15
+
6- Add your config unit tests under generated package config_test.go
16
+
7- Add your contract unit tests under generated package contract_test.go
17
+
8- Additionally you can add a full-fledged VM test for your precompile under plugin/vm/vm_test.go. See existing precompile tests for examples.
18
+
9- Add your solidity interface and test contract to contract-examples/contracts
19
+
10- Write solidity tests for your precompile in contract-examples/test
20
+
11- Create your genesis with your precompile enabled in tests/e2e/genesis/
21
+
12- Create e2e test for your solidity test in tests/e2e/solidity/suites.go
22
+
13- Run your e2e precompile Solidity tests with 'E2E=true ./scripts/run.sh
0 commit comments