Go: cmd/asm/internal/flags Index | Files

package flags

import "cmd/asm/internal/flags"

Package flags implements top-level flags and the usage message for the assembler.


Package Files



var (
    Debug      = flag.Bool("debug", false, "dump instructions as they are parsed")
    OutputFile = flag.String("o", "", "output file; default foo.o for /a/b/c/foo.s as first argument")
    PrintOut   = flag.Bool("S", false, "print assembly and machine code")
    TrimPath   = flag.String("trimpath", "", "remove prefix from recorded source file paths")
    Shared     = flag.Bool("shared", false, "generate code that can be linked into a shared library")
    Dynlink    = flag.Bool("dynlink", false, "support references to Go symbols defined in other shared libraries")
    AllErrors  = flag.Bool("e", false, "no limit on number of errors reported")
    SymABIs    = flag.Bool("gensymabis", false, "write symbol ABI information to output file, don't assemble")
    Importpath = flag.String("p", "", "set expected package import to path")
    Spectre    = flag.String("spectre", "", "enable spectre mitigations in `list` (all, ret)")

    Go115Newobj = flag.Bool("go115newobj", true, "use new object file format")

func Parse Uses

func Parse()

func Usage Uses

func Usage()

type MultiFlag Uses

type MultiFlag []string

MultiFlag allows setting a value multiple times to collect a list, as in -I=dir1 -I=dir2.

var (
    D   MultiFlag
    I   MultiFlag

func (*MultiFlag) Set Uses

func (m *MultiFlag) Set(val string) error

func (*MultiFlag) String Uses

func (m *MultiFlag) String() string

Package flags imports 6 packages (graph) and is imported by 7 packages. Updated 2021-01-22. Refresh now. Tools for package owners.