<?xml version="1.0" encoding="utf-8"?>
<feed xml:lang="en" xmlns="http://www.w3.org/2005/Atom"><title>Recent changes to tickets</title><link href="https://sourceforge.net/p/xpl-compiler/tickets/" rel="alternate"/><link href="https://sourceforge.net/p/xpl-compiler/tickets/feed.atom" rel="self"/><id>https://sourceforge.net/p/xpl-compiler/tickets/</id><updated>2020-07-04T10:19:00.620000Z</updated><subtitle>Recent changes to tickets</subtitle><entry><title>#7 factor out a function for argc, argc with xpl -m</title><link href="https://sourceforge.net/p/xpl-compiler/tickets/7/?limit=25#a45b" rel="alternate"/><published>2020-07-04T10:19:00.620000Z</published><updated>2020-07-04T10:19:00.620000Z</updated><author><name>Brian Tiffin</name><uri>https://sourceforge.net/u/btiffin/</uri></author><id>https://sourceforge.net912f3b95299bb285d53bdf1b0cce5a6a0e95aa12</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;:-)&lt;/p&gt;
&lt;p&gt;Yes and no.  As I was about to try and write up a minimal. I can't quite get the incantations that left the descriptors unset.  All works as advertised.&lt;/p&gt;
&lt;p&gt;I was early exploring, and using sed to rename function entries generated, and when trying to reproduce, it all just works, Daniel, no traceback.&lt;/p&gt;
&lt;div class="codehilite"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;prompt$ make tryargs
xpl -I -m args.xpl
XPL to C language translator -- version 0.6
12 cards containing 9 statements were compiled.
No errors were detected.
args
XPL command line arguments
0 
date: 120186 (year - 1900) * 1000 + day of year
time: 2053243 centiseconds since midnight
GnuCOBOL/XPL trial complete
&lt;/pre&gt;&lt;/div&gt;


&lt;p&gt;args.xpl as&lt;/p&gt;
&lt;div class="codehilite"&gt;&lt;pre&gt;&lt;span&gt;&lt;/span&gt;&lt;span class="cm"&gt;/* display CLI args */&lt;/span&gt;
&lt;span class="nv"&gt;args&lt;/span&gt;: &lt;span class="nv"&gt;procedure&lt;/span&gt;&lt;span class="c1"&gt;;&lt;/span&gt;
  &lt;span class="nv"&gt;output&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s1"&gt;'&lt;/span&gt;&lt;span class="s"&gt;XPL command line arguments&lt;/span&gt;&lt;span class="s1"&gt;'&lt;/span&gt;&lt;span class="c1"&gt;;&lt;/span&gt;
  &lt;span class="nv"&gt;output&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nv"&gt;argc&lt;/span&gt; &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="s1"&gt;'&lt;/span&gt;&lt;span class="s"&gt; &lt;/span&gt;&lt;span class="s1"&gt;'&lt;/span&gt; &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="nv"&gt;argv&lt;/span&gt;&lt;span class="ss"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="ss"&gt;)&lt;/span&gt;&lt;span class="c1"&gt;;&lt;/span&gt;
  &lt;span class="nv"&gt;declare&lt;/span&gt; &lt;span class="nv"&gt;i&lt;/span&gt; &lt;span class="nv"&gt;bit&lt;/span&gt;&lt;span class="ss"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;16&lt;/span&gt;&lt;span class="ss"&gt;)&lt;/span&gt;&lt;span class="c1"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;do&lt;/span&gt; &lt;span class="nv"&gt;i&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nv"&gt;argc&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt; &lt;span class="nv"&gt;to&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt; &lt;span class="nv"&gt;by&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="c1"&gt;;&lt;/span&gt;
    &lt;span class="nv"&gt;output&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s1"&gt;'&lt;/span&gt;&lt;span class="s"&gt;    &lt;/span&gt;&lt;span class="s1"&gt;'&lt;/span&gt; &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="nv"&gt;argv&lt;/span&gt;&lt;span class="ss"&gt;(&lt;/span&gt;&lt;span class="nv"&gt;i&lt;/span&gt;&lt;span class="ss"&gt;)&lt;/span&gt;&lt;span class="c1"&gt;;&lt;/span&gt;
  &lt;span class="k"&gt;end&lt;/span&gt;&lt;span class="c1"&gt;;&lt;/span&gt;
  &lt;span class="nv"&gt;output&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s1"&gt;'&lt;/span&gt;&lt;span class="s"&gt;date: &lt;/span&gt;&lt;span class="s1"&gt;'&lt;/span&gt; &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="nv"&gt;date&lt;/span&gt; &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="s1"&gt;'&lt;/span&gt;&lt;span class="s"&gt; (year - 1900) * 1000 + day of year&lt;/span&gt;&lt;span class="s1"&gt;'&lt;/span&gt;&lt;span class="c1"&gt;;&lt;/span&gt;
  &lt;span class="nv"&gt;output&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="s1"&gt;'&lt;/span&gt;&lt;span class="s"&gt;time: &lt;/span&gt;&lt;span class="s1"&gt;'&lt;/span&gt; &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="nv"&gt;time&lt;/span&gt; &lt;span class="o"&gt;||&lt;/span&gt; &lt;span class="s1"&gt;'&lt;/span&gt;&lt;span class="s"&gt; centiseconds since midnight&lt;/span&gt;&lt;span class="s1"&gt;'&lt;/span&gt;&lt;span class="c1"&gt;;&lt;/span&gt;
&lt;span class="k"&gt;end&lt;/span&gt; &lt;span class="nv"&gt;args&lt;/span&gt;&lt;span class="c1"&gt;;&lt;/span&gt;
&lt;span class="nv"&gt;eof&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;


&lt;p&gt;You can close this, I think.  I can't find screen history for a transcript,  It was a nice traceback from the XPL runtime.  I was changing generated sources of both xpl0006 and cobc to experiment, and will take blame for mixing something up.  It might have been a top level sans procedure label.  :-)&lt;/p&gt;
&lt;p&gt;Turns out there is no need to tweal code gen, and everything just works with -m.&lt;/p&gt;
&lt;p&gt;I'll continue to explore where XPL might meld with COBOL.  Nice work.&lt;/p&gt;
&lt;p&gt;Cheers,&lt;br/&gt;
Blue&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>factor out a function for argc, argc with xpl -m</title><link href="https://sourceforge.net/p/xpl-compiler/tickets/7/" rel="alternate"/><published>2020-07-04T04:50:04.226000Z</published><updated>2020-07-04T04:50:04.226000Z</updated><author><name>Brian Tiffin</name><uri>https://sourceforge.net/u/btiffin/</uri></author><id>https://sourceforge.nete0b38ff01aac16f07850bcaf8c0f7051ee9acc1d</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;Recently interested in XPL, and nicely done.  If you are still updating any of this Daniel... this is a feature request.&lt;/p&gt;
&lt;p&gt;I'm demoing some ways of integrating your XPL with GnuCOBOL, which also compiles to C.  It would be nice to have the argc, argv predefined XPL variable descriptors filled in via function call and not just when main is emiited (the normal no -m option adds the argc argv init with access to field names which gets hidden in the XPL -&amp;gt; C, GnuCOBOL -&amp;gt; C, C-&amp;gt;ELF tool chain.  GnuCOBOL CALL only exposes link symbols to functions, and the emitted code has uneasy acces to C variable names.&lt;/p&gt;
&lt;p&gt;Not that modular xpl0006 code is meant to know about the CLI, but XPL code that compiles fine can abend with report at runtime. Nice, by the way, but if the XPL code happens to access argc or argv() xpl builtins the script has no presets.  Either a function wrapper to init the descriptors or assume just the program name?&lt;/p&gt;
&lt;p&gt;Not a biggy in terms of priority or need (but also not completely useless).  Whims of trying out a 1972 COBOL based library with a CALL interface into XPL domain specific command interpreters.  &lt;/p&gt;
&lt;p&gt;Hercules MVS3.8 Tk4-, with ANS COBOL 1972 and XPL from SHARE sources compile fine in 2020 GnuCOBOL and thanks to your port, xpl0006, with nice interopt on the modern side.&lt;/p&gt;
&lt;p&gt;Sample of some of the efforts at &lt;a href="https://sourceforge.net/p/open-cobol/discussion/contrib/thread/dca517cdd9"&gt;https://sourceforge.net/p/open-cobol/discussion/contrib/thread/dca517cdd9&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Have good, make well,&lt;br/&gt;
Blue, btiffin@gnu.org&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>factor out a function for argc, argc with xpl -m</title><link href="https://sourceforge.net/p/xpl-compiler/tickets/7/" rel="alternate"/><published>2020-07-04T04:50:04.226000Z</published><updated>2020-07-04T04:50:04.226000Z</updated><author><name>Brian Tiffin</name><uri>https://sourceforge.net/u/btiffin/</uri></author><id>https://sourceforge.net97a9b0737dff83d434fba6cb82efe0f0ccf279df</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Ticket 7 has been modified: factor out a function for argc, argc with xpl -m&lt;br/&gt;
Edited By: Daniel Weaver (shoefoot)&lt;br/&gt;
Status updated: 'open' =&amp;gt; 'wont-fix'&lt;br/&gt;
_milestone updated: '1.0' =&amp;gt; '2.0'&lt;br/&gt;
Owner updated: None =&amp;gt; 'shoefoot'&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>#5 Hex constants at the end of a C compatible string are ignored</title><link href="https://sourceforge.net/p/xpl-compiler/tickets/5/?limit=25#8151" rel="alternate"/><published>2018-01-10T05:33:09.947000Z</published><updated>2018-01-10T05:33:09.947000Z</updated><author><name>Daniel Weaver</name><uri>https://sourceforge.net/u/shoefoot/</uri></author><id>https://sourceforge.net2b6fd3cb3129179de61bd36073ce4c3cf4d5edea</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;labels&lt;/strong&gt;:  --&amp;gt; 0.5&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;status&lt;/strong&gt;: open --&amp;gt; closed&lt;/li&gt;
&lt;/ul&gt;&lt;/div&gt;</summary></entry><entry><title>#6 Do loop iteration variable set too early</title><link href="https://sourceforge.net/p/xpl-compiler/tickets/6/?limit=25#6f9f" rel="alternate"/><published>2018-01-10T05:31:38.820000Z</published><updated>2018-01-10T05:31:38.820000Z</updated><author><name>Daniel Weaver</name><uri>https://sourceforge.net/u/shoefoot/</uri></author><id>https://sourceforge.net714983c3377b93bd0aac3293b22e4e4abc654fce</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;labels&lt;/strong&gt;:  --&amp;gt; 0.5&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;status&lt;/strong&gt;: open --&amp;gt; closed&lt;/li&gt;
&lt;/ul&gt;&lt;/div&gt;</summary></entry><entry><title>Do loop iteration variable set too early</title><link href="https://sourceforge.net/p/xpl-compiler/tickets/6/" rel="alternate"/><published>2017-12-25T00:49:56.152000Z</published><updated>2017-12-25T00:49:56.152000Z</updated><author><name>Daniel Weaver</name><uri>https://sourceforge.net/u/shoefoot/</uri></author><id>https://sourceforge.net5775084981f3446d89d84d7d21067613c6c2cbaf</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;The DO loop iteration variable gets set too early.  If the iteration variable is used in the limit expression or the step, the DO loop will execute the wrong number of times.&lt;br/&gt;
declare x fixed;&lt;br/&gt;
x = 20;&lt;br/&gt;
do x = 0 to x;&lt;br/&gt;
   /&lt;em&gt; This should loop 21 times &lt;/em&gt;/&lt;br/&gt;
end;&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>Do loop iteration variable set too early</title><link href="https://sourceforge.net/p/xpl-compiler/tickets/6/" rel="alternate"/><published>2017-12-25T00:49:56.152000Z</published><updated>2017-12-25T00:49:56.152000Z</updated><author><name>Daniel Weaver</name><uri>https://sourceforge.net/u/shoefoot/</uri></author><id>https://sourceforge.net139bb5ac2ed97d92e52ee72b6e0b595c1f815500</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Ticket 6 has been modified: Do loop iteration variable set too early&lt;br/&gt;
Edited By: Daniel Weaver (shoefoot)&lt;br/&gt;
Status updated: u'open' =&amp;gt; u'closed'&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>Hex constants at the end of a C compatible string are ignored</title><link href="https://sourceforge.net/p/xpl-compiler/tickets/5/" rel="alternate"/><published>2017-12-17T12:02:38.629000Z</published><updated>2017-12-17T12:02:38.629000Z</updated><author><name>Daniel Weaver</name><uri>https://sourceforge.net/u/shoefoot/</uri></author><id>https://sourceforge.netd460b61123419165ec29b0c8da735e904539ca0e</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;When using C compatable strings a hex constant will be ignored if used as the last character of a string.&lt;br/&gt;
  declare foo character initial("(c)\x31\x32");&lt;br/&gt;
The length of string foo is one.  It should be length two.&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>Hex constants at the end of a C compatible string are ignored</title><link href="https://sourceforge.net/p/xpl-compiler/tickets/5/" rel="alternate"/><published>2017-12-17T12:02:38.629000Z</published><updated>2017-12-17T12:02:38.629000Z</updated><author><name>Daniel Weaver</name><uri>https://sourceforge.net/u/shoefoot/</uri></author><id>https://sourceforge.net186546fee0e5be0354ff68e78fc7d8f8fe05f0d0</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Ticket 5 has been modified: Hex constants at the end of a C compatible string are ignored&lt;br/&gt;
Edited By: Daniel Weaver (shoefoot)&lt;br/&gt;
Status updated: u'open' =&amp;gt; u'closed'&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>#4 64-bit COREWORD()</title><link href="https://sourceforge.net/p/xpl-compiler/tickets/4/?limit=25#c83b" rel="alternate"/><published>2017-12-16T06:57:34.342000Z</published><updated>2017-12-16T06:57:34.342000Z</updated><author><name>Daniel Weaver</name><uri>https://sourceforge.net/u/shoefoot/</uri></author><id>https://sourceforge.net6db1e9efc6f16f223d6fa8c70222a0e6c850fed8</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;labels&lt;/strong&gt;:  --&amp;gt; 0.4&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;status&lt;/strong&gt;: open --&amp;gt; closed&lt;/li&gt;
&lt;/ul&gt;&lt;/div&gt;</summary></entry></feed>