aboutsummaryrefslogtreecommitdiff
path: root/src/ls_goto.h
blob: 39ff271c7e140f13d01881f9d3da59b3c299646e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
// This software disclaims copyright. Do what you want with it. Be gay, do
// crime. Originally written by Alexis Lockwood in 2021. Ⓐ

#ifndef LS_GOTO_H
#define LS_GOTO_H

// --- DEPENDENCIES ------------------------------------------------------------

// Supporting modules
#include "ls.h"

// Standard headers
#include <stdbool.h>
#include <stddef.h>
#include <inttypes.h>

// --- PUBLIC MACROS -----------------------------------------------------------
// --- PRIVATE DATATYPES -------------------------------------------------------
// --- PUBLIC DATATYPES --------------------------------------------------------
// --- PUBLIC CONSTANTS --------------------------------------------------------
// --- PUBLIC VARIABLES --------------------------------------------------------
// --- PUBLIC FUNCTIONS --------------------------------------------------------

/// Go to a numbered label.
///
/// @param self
/// @param backward - whether to look backwards for the label (otherwise
///   forwards)
/// @param num - number to go to
void ls_goto_num(ls_t * self, bool backward, uint16_t num);

/// Go to an ident (string) label.
///
/// @param self
/// @param ident - ident to go to
void ls_goto_ident(ls_t * self, char const * ident);

#endif // !defined(LS_GOTO_H)