Skip to content

Commit

Permalink
_content/doc/go1.24: edit debug/elf section
Browse files Browse the repository at this point in the history
This API changed since this section was written. Also, make it much
more succinct.

Change-Id: Id22dd3203b453d245e40d91dccc2dc2e1a42e672
Reviewed-on: https://go-review.googlesource.com/c/website/+/638879
LUCI-TryBot-Result: Go LUCI <[email protected]>
Reviewed-by: Ian Lance Taylor <[email protected]>
  • Loading branch information
aclements committed Jan 2, 2025
1 parent 4363924 commit 660603b
Showing 1 changed file with 11 additions and 19 deletions.
30 changes: 11 additions & 19 deletions _content/doc/go1.24.md
Original file line number Diff line number Diff line change
Expand Up @@ -514,27 +514,19 @@ revert to recomputing the CRT values.

#### [`debug/elf`](/pkg/debug/elf/)

The [`debug/elf`](/pkg/debug/elf) package adds several new constants, types, and methods to add support for handling dynamic versions and version flags in ELF (Executable and Linkable Format) files:

Several new types have been introduced:
- [`DynamicVersion`](/pkg/debug/elf#DynamicVersion) struct represents a dynamic version entry in the ELF file.
- [`DynamicVersionDep`](/pkg/debug/elf#DynamicVersionDep) struct represents a dependency of a dynamic version.
- [`DynamicVersionNeed`](/pkg/debug/elf#DynamicVersionNeed) struct represents a required dynamic version in the ELF file.
- [`DynamicVersionFlag`](/pkg/debug/elf#DynamicVersionFlag) is a new type defined as uint16, representing flags for dynamic versions.
- [`VER_FLG_BASE`](/pkg/debug/elf#VER_FLG_BASE) version definition of the file.
- [`VER_FLG_WEAK`](/pkg/debug/elf#VER_FLG_WEAK) weak version identifier.
- [`VER_FLG_INFO`](/pkg/debug/elf#VER_FLG_INFO) reference exists for informational purposes.
- [`SymbolVersionFlag`](/pkg/debug/elf#SymbolVersionFlag) is a new type defined as uint8, representing version flags for ELF symbols.
- [`VerFlagNone`](/pkg/debug/elf#VerFlagNone) no flags.
- [`VerFlagLocal`](/pkg/debug/elf#VerFlagLocal) symbol has local scope.
- [`VerFlagGlobal`](/pkg/debug/elf#VerFlagGlobal) symbol has global scope.
- [`VerFlagHidden`](/pkg/debug/elf#VerFlagHidden) symbol is hidden.

The following methods have been added:
- [`File.DynamicVersionNeeds`](/pkg/debug/elf#File.DynamicVersionNeeds) method returns a list of dynamic version needs in the ELF file, representing dependencies required by the executable.
- [`File.DynamicVersions`](/pkg/debug/elf#File.DynamicVersions) retrieves a list of dynamic versions defined in the ELF file.
<!-- go.dev/issue/63952 -->

The [`debug/elf`](/pkg/debug/elf) package adds support for handling symbol
versions in dynamic ELF (Executable and Linkable Format) files.
The new [`File.DynamicVersions`](/pkg/debug/elf#File.DynamicVersions) method
returns a list of dynamic versions defined in the ELF file.
The new [`File.DynamicVersionNeeds`](/pkg/debug/elf#File.DynamicVersionNeeds)
method returns a list of dynamic versions required by this ELF file that are
defined in other ELF objects.
Finally, the new [`Symbol.HasVersion`](/pkg/debug/elf#Symbol) and
[`Symbol.VersionIndex`](/pkg/debug/elf#Symbol) fields indicate the version of a
symbol.

#### [`encoding`](/pkg/encoding/)

Two new interfaces, [`TextAppender`](/pkg/encoding#TextAppender) and [`BinaryAppender`](/pkg/encoding#BinaryAppender), have been
Expand Down

0 comments on commit 660603b

Please sign in to comment.