Source File
error.go
Belonging Package
github.com/d2lang/mathjax-go/internal/mhchem
// Copyright (c) 2015-2021 Martin Hensel// Copyright (c) 2026 luo-studio// Copyright (c) 2026 erweixin (upstream RaTeX)// SPDX-License-Identifier: Apache-2.0 AND MIT//// Go translation and modification of mhchemparser 4.1.1. Initial Go// translation structure adapted from github.com/Luo-Studio/go-tex (MIT).package mhchemimport// Error preserves the identifier and message pair thrown by mhchemparser.// TeX integrations can pass these fields directly to their native TexError.type Error struct {ID stringMessage string}func ( *Error) () string { return .Message }func parserError(, string) error { return &Error{ID: , Message: } }func errMsg( string, ...any) error {return parserError("MhchemError", "mhchem: "+fmt.Sprintf(, ...))}var errExtraClose = &Error{ID: "ExtraCloseMissingOpen",Message: "Extra close brace or missing open brace",}
![]() |
The pages are generated with Golds v0.8.7. (GOOS=linux GOARCH=amd64) Golds is a Go 101 project developed by Tapir Liu. PR and bug reports are welcome and can be submitted to the issue list. Please follow @zigo_101 (reachable from the left QR code) to get the latest news of Golds. |