2
2
3
3
The err2 package will offer auto-migration scripts until version 1.0.0 is
4
4
published. That means that you can safely use the package even the API is not
5
- yet 100% staple . We have used that approach for our production code that uses
5
+ yet 100% stable . We have used that approach for our production code that uses
6
6
` err2 ` and it works very well. Over 100 KLOC Go code has been auto-migrated
7
7
successfully from type variables (see below) to Go generics API.
8
8
@@ -13,12 +13,12 @@ functions or make something obsolete.
13
13
14
14
The version 0.9.40 is a major update because of the performance and API change.
15
15
We have managed to eliminate ` defer ` slowdown. Our benchmarks are 3x faster than
16
- previous version and about equal to those function call stacks (100 level) that
17
- don't use ` defer ` . We are exactly at the same level of performance with those
18
- functions that use deferred function that accept an argument. Transporting an
19
- argument to deferred function seems to be slower than functions that don't. And
20
- because ` try.To ` is already as fast as ` if err != nil ` we reached our goal for
21
- speed!
16
+ previous version and about equal to those function call stacks (100 deep- level)
17
+ that don't use ` defer ` . We are exactly at the same level of performance with
18
+ those functions that use deferred function that accept an argument. Transporting
19
+ an argument to deferred function seems to be slower than functions that don't.
20
+ And because ` try.To ` is already as fast as ` if err != nil ` we reached our goal
21
+ for speed!
22
22
23
23
Because all of the error handler function signatures are now:
24
24
``` go
@@ -35,7 +35,8 @@ important but difficult. The `err2` package writes `fatal error: ...` to
35
35
36
36
You have two (2) options for migration for v0.9.40:
37
37
1 . [ (Semi)-Automatic Migration] ( #semi-automatic-migration )
38
- 1 . [ Manual migration using (vim/nvim) location lists or similar] ( manual-migration-with-a-location-list )
38
+ 1 . [ Manual migration using (vim/nvim) location lists or
39
+ similar] ( #manual-migration-with-a-location-list )
39
40
40
41
#### (Semi)-Automatic Migration
41
42
0 commit comments