Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions src/FileFormats/LP/read.jl
Original file line number Diff line number Diff line change
Expand Up @@ -242,8 +242,8 @@ struct _Token
end

"""
mutable struct _LexerState
io::IO
mutable struct _LexerState{O<:IO}
io::O
line::Int
peek_char::Union{Nothing,Char}
peek_tokens::Vector{_Token}
Expand All @@ -257,12 +257,12 @@ A struct that is used to manage state when lexing. It stores:
* `peek_char`: the next `Char` in the `io`
* `peek_tokens`: the list of upcoming tokens that we have already peeked
"""
mutable struct _LexerState
io::IO
mutable struct _LexerState{O<:IO}
io::O
line::Int
peek_char::Union{Nothing,Char}
peek_tokens::Vector{_Token}
_LexerState(io::IO) = new(io, 1, nothing, _Token[])
_LexerState(io::IO) = new{typeof(io)}(io, 1, nothing, _Token[])
end

"""
Expand Down
Loading