mirror of
https://github.com/mikpe/pdp10-tools.git
synced 2026-01-23 19:08:00 +00:00
as: tunit: fix dialyzer error
This commit is contained in:
parent
629ee7993d
commit
38ca3f4d40
@ -642,8 +642,8 @@ expr_fixup(Tunit, Expr) ->
|
||||
|
||||
tunit_init() ->
|
||||
SectionText = section_dot_text(),
|
||||
Tunit = tunit:put_section(tunit:new(), SectionText),
|
||||
Tunit#tunit{cursect = SectionText#section.name}.
|
||||
Cursect = SectionText#section.name,
|
||||
tunit:put_section(tunit:new(Cursect), SectionText).
|
||||
|
||||
%% Predefined Sections ---------------------------------------------------------
|
||||
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
%%% -*- erlang-indent-level: 2 -*-
|
||||
%%%
|
||||
%%% translation unit handling for pdp10-elf as.
|
||||
%%% Copyright (C) 2013-2019 Mikael Pettersson
|
||||
%%% Copyright (C) 2013-2020 Mikael Pettersson
|
||||
%%%
|
||||
%%% This file is part of pdp10-tools.
|
||||
%%%
|
||||
@ -20,7 +20,7 @@
|
||||
|
||||
-module(tunit).
|
||||
|
||||
-export([ new/0
|
||||
-export([ new/1
|
||||
, get_section/2
|
||||
, put_section/2
|
||||
, get_symbol/2
|
||||
@ -33,10 +33,10 @@
|
||||
|
||||
%% API -------------------------------------------------------------------------
|
||||
|
||||
-spec new() -> #tunit{}.
|
||||
new() ->
|
||||
-spec new(string()) -> #tunit{}.
|
||||
new(Cursect) ->
|
||||
#tunit{ sections = #{}
|
||||
, cursect = false
|
||||
, cursect = Cursect
|
||||
, symbols = #{}
|
||||
, local_labels = #{}
|
||||
}.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user