aboutsummaryrefslogtreecommitdiffstats
path: root/src/grt/grt-vstrings.ads
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2016-06-28 06:46:55 +0200
committerTristan Gingold <tgingold@free.fr>2016-06-28 06:46:55 +0200
commitecf964d43cfb36def48809fe47e43f60a5f2e4b1 (patch)
tree9dd3a4e4fde84001e0b884b812976952340d5992 /src/grt/grt-vstrings.ads
parent9d38f14e5180a4b30c4dbb11ecbf954b3473bce9 (diff)
downloadghdl-ecf964d43cfb36def48809fe47e43f60a5f2e4b1.tar.gz
ghdl-ecf964d43cfb36def48809fe47e43f60a5f2e4b1.tar.bz2
ghdl-ecf964d43cfb36def48809fe47e43f60a5f2e4b1.zip
vpi: use a variable buffer for vpi_get_value.
vstrings: add Reset and Get_C_String. Close #98
Diffstat (limited to 'src/grt/grt-vstrings.ads')
-rw-r--r--src/grt/grt-vstrings.ads5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/grt/grt-vstrings.ads b/src/grt/grt-vstrings.ads
index 94967bb0f..067b54c6b 100644
--- a/src/grt/grt-vstrings.ads
+++ b/src/grt/grt-vstrings.ads
@@ -34,6 +34,9 @@ package Grt.Vstrings is
-- Deallocate all storage internally allocated.
procedure Free (Vstr : in out Vstring);
+ -- Reset VSTR to an empty string.
+ procedure Reset (Vstr : in out Vstring);
+
-- Append a character.
procedure Append (Vstr : in out Vstring; C : Character);
@@ -53,6 +56,8 @@ package Grt.Vstrings is
-- Display VSTR.
procedure Put (Stream : FILEs; Vstr : Vstring);
+ -- Get VSTR as a C String. The NUL character must have been added.
+ function Get_C_String (Vstr : Vstring) return Ghdl_C_String;
-- A Rstring is link a Vstring but characters can only be prepended.
type Rstring is limited private;