logger

package
v0.0.0-...-1bfbc23 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 24, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Overview

copied from https://github.com/xNaCly/tiny-interpreter/blob/master/logger/logger.go

Index

Constants

View Source
const (
	ANSI_RESET   = "\033[0m"
	ANSI_CLEAR   = "\033c"
	ANSI_RED     = "\033[91m"
	ANSI_YELLOW  = "\033[93m"
	ANSI_BLUE    = "\033[94m"
	ANSI_MAGENTA = "\033[95m"
)

Variables

View Source
var DEBUG = false
View Source
var SILENT = false

Functions

func L

func L(v ...any)

simple call to the log.Println function, only here to keep things isolated and consistent

func LDebug

func LDebug(v ...any)

func LError

func LError(s string)

prefixes s with 'error', calls log.Fatalln, prints result, exits with error code 1

func LInfo

func LInfo(s string)

prefixes s with 'info', prints result

func LWarn

func LWarn(s string)

prefixes s with 'warn', prints result

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL